Skip to content

Commit

Permalink
update ILM integ test cluster poll interval to 1s (#35113)
Browse files Browse the repository at this point in the history
  • Loading branch information
talevy authored Nov 1, 2018
1 parent 5f4b23f commit f8e23f6
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 3 deletions.
2 changes: 1 addition & 1 deletion x-pack/plugin/ilm/qa/multi-node/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ integTestCluster {
setting 'xpack.monitoring.enabled', 'false'
setting 'xpack.ml.enabled', 'false'
setting 'xpack.license.self_generated.type', 'trial'
setting 'indices.lifecycle.poll_interval', '2500ms'
setting 'indices.lifecycle.poll_interval', '1000ms'

}
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,19 @@ public void testFullPolicy() throws Exception {
updatePolicy(originalIndex, policy);
// index document {"foo": "bar"} to trigger rollover
index(client(), originalIndex, "_id", "foo", "bar");

/*
* These asserts are in the order that they should be satisfied in, in
* order to maximize the time for all operations to complete.
* An "out of order" assert here may result in this test occasionally
* timing out and failing inappropriately.
*/
// asserts that rollover was called
assertBusy(() -> assertTrue(indexExists(secondIndex)));
assertBusy(() -> assertFalse(indexExists(shrunkenOriginalIndex)));
// asserts that shrink deleted the original index
assertBusy(() -> assertFalse(indexExists(originalIndex)));
// asserts that the delete phase completed for the managed shrunken index
assertBusy(() -> assertFalse(indexExists(shrunkenOriginalIndex)));
}

public void testMoveToAllocateStep() throws Exception {
Expand Down Expand Up @@ -150,9 +160,19 @@ public void testMoveToRolloverStep() throws Exception {
" }\n" +
"}");
client().performRequest(moveToStepRequest);

/*
* These asserts are in the order that they should be satisfied in, in
* order to maximize the time for all operations to complete.
* An "out of order" assert here may result in this test occasionally
* timing out and failing inappropriately.
*/
// asserts that rollover was called
assertBusy(() -> assertTrue(indexExists(secondIndex)));
assertBusy(() -> assertFalse(indexExists(shrunkenOriginalIndex)));
// asserts that shrink deleted the original index
assertBusy(() -> assertFalse(indexExists(originalIndex)));
// asserts that the delete phase completed for the managed shrunken index
assertBusy(() -> assertFalse(indexExists(shrunkenOriginalIndex)));
}

public void testRolloverAction() throws Exception {
Expand Down

0 comments on commit f8e23f6

Please sign in to comment.