Skip to content

Commit 0651098

Browse files
committed
Fix testSingleIndexShardAllocation
Signed-off-by: Lakshya Taragi <lakshya.taragi@gmail.com>
1 parent 74b9b94 commit 0651098

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

server/src/internalClusterTest/java/org/opensearch/indices/replication/SegmentReplicationAllocationIT.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -170,14 +170,16 @@ public void testSingleIndexShardAllocation() throws Exception {
170170

171171
// Remove a node
172172
internalCluster().stopRandomNode(InternalTestCluster.nameFilter(nodeNames.get(0)));
173-
ensureGreen(TimeValue.timeValueSeconds(60));
173+
internalCluster().validateClusterFormed();
174+
ensureGreen(TimeValue.timeValueSeconds(100));
174175
state = client().admin().cluster().prepareState().execute().actionGet().getState();
175176
logger.info(ShardAllocations.printShardDistribution(state));
176177
verifyPerIndexPrimaryBalance();
177178

178179
// Add a new node
179180
internalCluster().startDataOnlyNode();
180-
ensureGreen(TimeValue.timeValueSeconds(60));
181+
internalCluster().validateClusterFormed();
182+
ensureGreen(TimeValue.timeValueSeconds(100));
181183
state = client().admin().cluster().prepareState().execute().actionGet().getState();
182184
logger.info(ShardAllocations.printShardDistribution(state));
183185
verifyPerIndexPrimaryBalance();

0 commit comments

Comments
 (0)