[Test] testSingleNodeWithFlush should wait for yellow
O.w. it can restart a node before all primaries are started , leading to a red state down the road...
This commit is contained in:
parent
80774877ff
commit
dcb2107a1d
|
@ -208,6 +208,9 @@ public class SimpleRecoveryLocalGatewayTests extends ElasticsearchIntegrationTes
|
|||
|
||||
assertHitCount(client().prepareCount().setQuery(matchAllQuery()).execute().actionGet(), 2);
|
||||
|
||||
ensureYellow("test"); // wait for primary allocations here otherwise if we have a lot of shards we might have a
|
||||
// shard that is still in post recovery when we restart and the ensureYellow() below will timeout
|
||||
|
||||
internalCluster().fullRestart();
|
||||
|
||||
logger.info("Running Cluster Health (wait for the shards to startup)");
|
||||
|
|
Loading…
Reference in New Issue