Skip to content
Permalink
Browse files
Destroy builds cache to bypass data corruption
  • Loading branch information
dspavlov committed Mar 11, 2019
1 parent da99a7a commit 3a8eb053180d0a424044549b787716ea9a9cddb9
Showing 1 changed file with 30 additions and 0 deletions.
@@ -56,6 +56,17 @@ public class RemoteClientTmpHelper {
public static String DUMPS = "dumps";
private static boolean dumpDict = false;


/**
* @param args Args.
*/
public static void main(String[] args) {
System.err.println("Please insert option of main");
}

/**
* @param args Args.
*/
public static void mainResetUser(String[] args) {
try (Ignite ignite = tcbotServerConnectedClient()) {
IgniteCache<Object, Object> users = ignite.cache(UserAndSessionsStorage.USERS);
@@ -65,6 +76,25 @@ public static void mainResetUser(String[] args) {
}
}

/**
* @param args Args.
*/
public static void mainDestroyAllFatBuilds(String[] args) {
int fatBuildsCnt;
try (Ignite ignite = tcbotServerConnectedClient()) {
IgniteCache<Object, Object> cacheHistEntries = ignite.cache( FatBuildDao.TEAMCITY_FAT_BUILD_CACHE_NAME);
fatBuildsCnt = cacheHistEntries.size();

System.err.println("Start destroy() operation for fat builds: " + fatBuildsCnt);
cacheHistEntries.destroy();
System.err.println("Finish destroy() operation");

}

System.err.println("Test hist entries destroyed: [" + fatBuildsCnt + "] builds");
}


public static void mainDestroyTestHist(String[] args) {
int testHist;
int buildStartTimes;

0 comments on commit 3a8eb05

Please sign in to comment.