Skip to content

Commit

Permalink
[TEST] Remove redundant cluster checks
Browse files Browse the repository at this point in the history
Removes ensureStableCluster() calls in ClusterAllocationExplainIT
testing after startNode*() calls. The stabilization checks were
originally necessary when the tests were added in #22182. However,
#49248 later enhanced validateClusterFormed(), which startNode*()
implicitly calls, to perform similar checks to ensureStableCluster()
  • Loading branch information
DiannaHohensee committed Aug 22, 2023
1 parent 6258b18 commit fa238a7
Showing 1 changed file with 0 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,6 @@ public void testUnassignedReplicaWithPriorCopy() throws Exception {
logger.info("--> restarting the stopped nodes");
internalCluster().startNode(Settings.builder().put("node.name", nodes.get(0)).put(node0DataPathSettings).build());
internalCluster().startNode(Settings.builder().put("node.name", nodes.get(1)).put(node1DataPathSettings).build());
ensureStableCluster(3);

boolean includeYesDecisions = randomBoolean();
boolean includeDiskInfo = randomBoolean();
Expand Down Expand Up @@ -612,7 +611,6 @@ public void testAllocationFilteringPreventsShardMove() throws Exception {
public void testRebalancingNotAllowed() throws Exception {
logger.info("--> starting a single node");
internalCluster().startNode();
ensureStableCluster(1);

prepareIndex(5, 0);

Expand All @@ -621,7 +619,6 @@ public void testRebalancingNotAllowed() throws Exception {

logger.info("--> starting another node, with rebalancing disabled, it should get no shards");
internalCluster().startNode();
ensureStableCluster(2);

boolean includeYesDecisions = randomBoolean();
boolean includeDiskInfo = randomBoolean();
Expand Down Expand Up @@ -720,7 +717,6 @@ public void testRebalancingNotAllowed() throws Exception {
public void testWorseBalance() throws Exception {
logger.info("--> starting a single node");
internalCluster().startNode();
ensureStableCluster(1);

prepareIndex(5, 0);

Expand All @@ -729,7 +725,6 @@ public void testWorseBalance() throws Exception {

logger.info("--> starting another node, with the rebalance threshold so high, it should not get any shards");
internalCluster().startNode();
ensureStableCluster(2);

boolean includeYesDecisions = randomBoolean();
boolean includeDiskInfo = randomBoolean();
Expand Down Expand Up @@ -820,7 +815,6 @@ public void testWorseBalance() throws Exception {
public void testBetterBalanceButCannotAllocate() throws Exception {
logger.info("--> starting a single node");
String firstNode = internalCluster().startNode();
ensureStableCluster(1);

prepareIndex(5, 0);

Expand All @@ -829,7 +823,6 @@ public void testBetterBalanceButCannotAllocate() throws Exception {

logger.info("--> starting another node, with filtering not allowing allocation to the new node, it should not get any shards");
internalCluster().startNode();
ensureStableCluster(2);

boolean includeYesDecisions = randomBoolean();
boolean includeDiskInfo = randomBoolean();
Expand Down

0 comments on commit fa238a7

Please sign in to comment.