Complete failing test early
@@ -227,6 +227,7 @@ public class CacheGroupsMetricsRebalanceTest extends GridCommonAbstractTest {
System.out.println("Wait until keys left will be less " + keysLine);
+ try {
while (finishRebalanceLatch.getCount() != 0) {
CacheMetrics m = ig2.cache(CACHE1).localMetrics();
@@ -247,9 +248,13 @@ public class CacheGroupsMetricsRebalanceTest extends GridCommonAbstractTest {
}
}
}
+ finally {
+ latch.countDown();
+ }
+ }
});
- latch.await();
+ assertTrue(latch.await(getTestTimeout(), TimeUnit.MILLISECONDS));
long finishTime = ig2.cache(CACHE1).localMetrics().getEstimatedRebalancingFinishTime();
