From 55426862834a60ce9189dff662131a243cfd9957 Mon Sep 17 00:00:00 2001 From: David Kyle Date: Mon, 16 Dec 2019 14:55:01 +0000 Subject: [PATCH] [ML] Wait for green after opening job in NetworkDisruptionIT (#50232) Closes #49908 --- .../elasticsearch/xpack/ml/integration/NetworkDisruptionIT.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x-pack/plugin/ml/src/test/java/org/elasticsearch/xpack/ml/integration/NetworkDisruptionIT.java b/x-pack/plugin/ml/src/test/java/org/elasticsearch/xpack/ml/integration/NetworkDisruptionIT.java index 379daba7c45..325e34fbf46 100644 --- a/x-pack/plugin/ml/src/test/java/org/elasticsearch/xpack/ml/integration/NetworkDisruptionIT.java +++ b/x-pack/plugin/ml/src/test/java/org/elasticsearch/xpack/ml/integration/NetworkDisruptionIT.java @@ -48,11 +48,11 @@ public class NetworkDisruptionIT extends BaseMlIntegTestCase { Job.Builder job = createJob("relocation-job", new ByteSizeValue(2, ByteSizeUnit.MB)); PutJobAction.Request putJobRequest = new PutJobAction.Request(job); client().execute(PutJobAction.INSTANCE, putJobRequest).actionGet(); - ensureGreen(); OpenJobAction.Request openJobRequest = new OpenJobAction.Request(job.getId()); AcknowledgedResponse openJobResponse = client().execute(OpenJobAction.INSTANCE, openJobRequest).actionGet(); assertTrue(openJobResponse.isAcknowledged()); + ensureGreen(); // Record which node the job starts off on String origJobNode = awaitJobOpenedAndAssigned(job.getId(), null);