Fix flaky tests.

Signed-off-by: Rabi Panda <adnapibar@gmail.com>
This commit is contained in:
Rabi Panda 2021-09-30 10:13:38 -07:00
parent b78e95b5b5
commit d7f2b09bae

View File

@ -234,8 +234,10 @@ public class ShardIndexingPressureConcurrentExecutionTests extends OpenSearchTes
assertTrue(nodeStats.getCurrentCombinedCoordinatingAndPrimaryBytes() < 50 * 200);
assertTrue(shardStats.getIndexingPressureShardStats(shardId1).getCurrentCombinedCoordinatingAndPrimaryBytes() < 50 * 200);
for (int i = 0; i < NUM_THREADS - rejectionCount.get(); i++) {
releasables[i].close();
for (Releasable releasable : releasables) {
if (releasable != null) {
releasable.close();
}
}
nodeStats = shardIndexingPressure.stats();