From 38afc9f27de580d86179553b73001b76c20b82fe Mon Sep 17 00:00:00 2001 From: Hendrik Muhs Date: Mon, 25 Mar 2019 11:57:11 +0100 Subject: [PATCH] refresh audit index before searching (#40401) refresh the audit index before searching --- .../xpack/dataframe/integration/DataFrameAuditorIT.java | 1 + 1 file changed, 1 insertion(+) diff --git a/x-pack/plugin/data-frame/qa/single-node-tests/src/test/java/org/elasticsearch/xpack/dataframe/integration/DataFrameAuditorIT.java b/x-pack/plugin/data-frame/qa/single-node-tests/src/test/java/org/elasticsearch/xpack/dataframe/integration/DataFrameAuditorIT.java index a84f39f63e7..750faf8dade 100644 --- a/x-pack/plugin/data-frame/qa/single-node-tests/src/test/java/org/elasticsearch/xpack/dataframe/integration/DataFrameAuditorIT.java +++ b/x-pack/plugin/data-frame/qa/single-node-tests/src/test/java/org/elasticsearch/xpack/dataframe/integration/DataFrameAuditorIT.java @@ -62,6 +62,7 @@ public class DataFrameAuditorIT extends DataFrameRestTestCase { // Make sure we wrote to the audit assertTrue(indexExists(DataFrameInternalIndex.AUDIT_INDEX)); + refreshIndex(DataFrameInternalIndex.AUDIT_INDEX); Request request = new Request("GET", DataFrameInternalIndex.AUDIT_INDEX + "/_search"); request.setJsonEntity("{\"query\":{\"term\":{\"transform_id\":\"simplePivotForAudit\"}}}"); Map response = entityAsMap(client().performRequest(request));