Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow Bulk Snapshot Deletes to Abort #56009

Merged

Conversation

original-brownbear
Copy link
Member

@original-brownbear original-brownbear commented Apr 30, 2020

Making use of #55773 to simplify snapshot state machine.

  1. Deletes with no in-progress snapshot now add the delete entry to the cluster state right away
    instead of doing a second CS update after the fist update was a NOOP.
  2. If a bulk delete matches in-progress as well as completed snapshots, abort the in-progress snapshot and then move on to delete from the repository.

NOTE: I didn't refactor things significantly in this PR for now to keep the change-set limited but there's a number of possible follow-ups here to simplify the state update task nesting away and make things much easier to read.

Making use of elastic#55773 to simplify snapshot state machine.
1. Deletes with no in-progress snapshot now add the delete entry to the cluster state right away
instead of doing a second CS update after the fist update was a NOOP.
2. If a bulk delete matches in-progress as well as completed snapshots, abort the in-progress snapshot
and then move on to delete from the repository.
@original-brownbear
Copy link
Member Author

Jenkins test this

Copy link
Member

@tlrx tlrx left a comment

Choose a reason for hiding this comment

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

LGTM

@original-brownbear
Copy link
Member Author

Thanks Tanguy!

@original-brownbear original-brownbear merged commit 84522d2 into elastic:master May 4, 2020
@original-brownbear original-brownbear deleted the one-stop-delete branch May 4, 2020 12:57
original-brownbear added a commit to original-brownbear/elasticsearch that referenced this pull request May 4, 2020
Making use of elastic#55773 to simplify snapshot state machine.
1. Deletes with no in-progress snapshot now add the delete entry to the cluster state right away
instead of doing a second CS update after the fist update was a NOOP.
2. If a bulk delete matches in-progress as well as completed snapshots, abort the in-progress snapshot
and then move on to delete from the repository.
original-brownbear added a commit that referenced this pull request May 4, 2020
Making use of #55773 to simplify snapshot state machine.
1. Deletes with no in-progress snapshot now add the delete entry to the cluster state right away
instead of doing a second CS update after the fist update was a NOOP.
2. If a bulk delete matches in-progress as well as completed snapshots, abort the in-progress snapshot
and then move on to delete from the repository.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants