[TEST] testAckedIndexing waits for the cluster state to have propogated
to all nodes in the cluster before checking the existance of documents on each node
This commit is contained in:
parent
1169cd936e
commit
ce811feba7
|
@ -584,6 +584,16 @@ public class DiscoveryWithServiceDisruptionsIT extends ESIntegTestCase {
|
||||||
}
|
}
|
||||||
ensureGreen("test");
|
ensureGreen("test");
|
||||||
|
|
||||||
|
// make sure all nodes have the updated cluster state with the latest routing table
|
||||||
|
final long clusterStateVersionOnMaster = internalCluster().clusterService(internalCluster().getMasterName())
|
||||||
|
.state().getVersion();
|
||||||
|
assertBusy(() -> {
|
||||||
|
for (String node : nodes) {
|
||||||
|
assertThat(internalCluster().clusterService(node).state().getVersion(),
|
||||||
|
greaterThanOrEqualTo(clusterStateVersionOnMaster));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
logger.info("validating successful docs");
|
logger.info("validating successful docs");
|
||||||
for (String node : nodes) {
|
for (String node : nodes) {
|
||||||
try {
|
try {
|
||||||
|
|
Loading…
Reference in New Issue