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

cluster: avoid throwing on duplicate recovery #17563

Merged
merged 1 commit into from
Apr 3, 2024

Conversation

andrwng
Copy link
Contributor

@andrwng andrwng commented Apr 3, 2024

This adds a conservative check for in-progress recoveries at bootstrap time: if a recovery is in progress, we will log an error message instead of throwing.

In practice we don't expect this error code to be hit, but in case of a bug or somesuch, this seems preferable over throwing and blocking applying controller messages.

Note that update_in_progress is the only error code to come out of cluster_recovery_table::apply().

Backports Required

  • none - not a bug fix
  • none - this is a backport
  • none - issue does not exist in previous branches
  • none - papercut/not impactful enough to backport
  • v23.3.x
  • v23.2.x

Release Notes

  • none

This adds a conservative check for in-progress recoveries at bootstrap
time: if a recovery is in progress, we will log an error message instead
of throwing.

In practice we don't expect this error code to be hit, but in case of a
bug or somesuch, this seems preferable over throwing and blocking
applying controller messages.

Note that update_in_progress is the only error code to come out of
cluster_recovery_table::apply().
@vbotbuildovich
Copy link
Collaborator

vbotbuildovich commented Apr 3, 2024

@andrwng
Copy link
Contributor Author

andrwng commented Apr 3, 2024

Thanks for the review!

@andrwng andrwng merged commit c18c04c into redpanda-data:dev Apr 3, 2024
18 checks passed
@vbotbuildovich
Copy link
Collaborator

/backport v23.3.x

@vbotbuildovich
Copy link
Collaborator

Failed to create a backport PR to v23.3.x branch. I tried:

git remote add upstream https://github.com/redpanda-data/redpanda.git
git fetch --all
git checkout -b backport-pr-17563-v23.3.x-853 remotes/upstream/v23.3.x
git cherry-pick -x 14663a988851ad3d8e547469d11d33bab47a6d5f

Workflow run logs.

@dotnwat
Copy link
Member

dotnwat commented Apr 3, 2024

@andrwng why backport? wasn't this all a clang-tidy cleanup patch to begin with?

@andrwng
Copy link
Contributor Author

andrwng commented Apr 3, 2024

@andrwng why backport? wasn't this all a clang-tidy cleanup patch to begin with?

Ah I thought the cleanup patch was being backported so I followed suit. Will close the backport since looks like that backport has also been closed

@dotnwat
Copy link
Member

dotnwat commented Apr 3, 2024

ahh, right on. yeh seems like maybe it won't be backported as there were some conflicts or something.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants