Skip to content

Make the UpdateRolloverLifecycleDateStep retryable#50702

Merged
andreidan merged 3 commits intoelastic:masterfrom
andreidan:ilm-update-rollover-lifecycle-date-retryable
Jan 8, 2020
Merged

Make the UpdateRolloverLifecycleDateStep retryable#50702
andreidan merged 3 commits intoelastic:masterfrom
andreidan:ilm-update-rollover-lifecycle-date-retryable

Conversation

@andreidan
Copy link
Copy Markdown
Contributor

This makes the "update-rollover-lifecycle-date" step, which is part of the
rollover action, retryable. It also adds an integration test to check the
step is retried and it eventually succeeds.

Related to #48183

This makes the "update-rollover-lifecycle-date" step, which is part of the
rollover action, retryable. It also adds an integration test to check the
step is retried and it eventually succeeds.
@andreidan andreidan added >enhancement :Data Management/ILM+SLM DO NOT USE. Use ":StorageEngine/ILM" or ":Distributed Coordination/SLM" instead. v8.0.0 v7.6.0 labels Jan 7, 2020
@elasticmachine
Copy link
Copy Markdown
Collaborator

Pinging @elastic/es-core-features (:Core/Features/ILM+SLM)

@andreidan andreidan requested a review from dakrone January 7, 2020 14:09
Copy link
Copy Markdown
Member

@dakrone dakrone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, I left one comment. Fantastic that it's not too hard to make these retryable now :)

Map<String, Object> explainIndexResponse = explainIndex(index);
String step = (String) explainIndexResponse.get("step");
Integer retryCount = (Integer) explainIndexResponse.get(FAILED_STEP_RETRY_COUNT_FIELD);
return step != null && step.equals(UpdateRolloverLifecycleDateStep.NAME) && retryCount != null && retryCount >= 2;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be 1 instead of 2?

@andreidan
Copy link
Copy Markdown
Contributor Author

LGTM, I left one comment. Fantastic that it's not too hard to make these retryable now :)

Yeah, it's only the testing that requires some gymnastics :)

@andreidan andreidan merged commit 5bf0685 into elastic:master Jan 8, 2020
andreidan added a commit to andreidan/elasticsearch that referenced this pull request Jan 8, 2020
This makes the "update-rollover-lifecycle-date" step, which is part of the
rollover action, retryable. It also adds an integration test to check the
step is retried and it eventually succeeds.

(cherry picked from commit 5bf0685)
Signed-off-by: Andrei Dan <andrei.dan@elastic.co>
andreidan added a commit that referenced this pull request Jan 8, 2020
This makes the "update-rollover-lifecycle-date" step, which is part of the
rollover action, retryable. It also adds an integration test to check the
step is retried and it eventually succeeds.

(cherry picked from commit 5bf0685)
Signed-off-by: Andrei Dan <andrei.dan@elastic.co>
SivagurunathanV pushed a commit to SivagurunathanV/elasticsearch that referenced this pull request Jan 23, 2020
This makes the "update-rollover-lifecycle-date" step, which is part of the
rollover action, retryable. It also adds an integration test to check the
step is retried and it eventually succeeds.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Data Management/ILM+SLM DO NOT USE. Use ":StorageEngine/ILM" or ":Distributed Coordination/SLM" instead. >enhancement v7.6.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants