Skip to content

Commit

Permalink
[Transform] Make Transform Feature Reset really wait for all the tasks (
Browse files Browse the repository at this point in the history
  • Loading branch information
przemekwitek authored Oct 11, 2023
1 parent 937f2db commit 5bdf4ac
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
5 changes: 5 additions & 0 deletions docs/changelog/100624.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
pr: 100624
summary: Make Transform Feature Reset really wait for all the tasks
area: Transform
type: bug
issues: []
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,8 @@ public void testTransformFeatureReset() throws Exception {
assertThat((Integer) getTransforms("_all").get("count"), equalTo(0));

// assert transform indices are gone
assertThat(ESRestTestCase.entityAsMap(adminClient().performRequest(new Request("GET", ".transform-*"))), is(anEmptyMap()));
Map<String, Object> transformIndices = ESRestTestCase.entityAsMap(adminClient().performRequest(new Request("GET", ".transform-*")));
assertThat("Indices were: " + transformIndices, transformIndices, is(anEmptyMap()));
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,7 @@ public void cleanUpFeature(
client.admin()
.cluster()
.prepareListTasks()
.setActions(TransformField.TASK_NAME)
.setActions(TransformField.TASK_NAME + "*")
.setWaitForCompletion(true)
.execute(ActionListener.wrap(listTransformTasks -> {
listTransformTasks.rethrowFailures("Waiting for transform tasks");
Expand Down

0 comments on commit 5bdf4ac

Please sign in to comment.