[release/v25.1.x] topic: allow finalizer removal when broker is unreachable#1255
Closed
github-actions[bot] wants to merge 1 commit intorelease/v25.1.xfrom
Closed
[release/v25.1.x] topic: allow finalizer removal when broker is unreachable#1255github-actions[bot] wants to merge 1 commit intorelease/v25.1.xfrom
github-actions[bot] wants to merge 1 commit intorelease/v25.1.xfrom
Conversation
d27989d to
f0605d1
Compare
Topics were getting stuck in Terminating state when the Kafka broker was unreachable (connection refused, DNS failure, etc.) or when credentials were missing. The controller kept retrying forever, blocking namespace deletion. Fix by detecting non-recoverable connection errors during topic deletion and allowing the finalizer to be removed. This handles: - Missing credentials Secret or cloud secret (NotFound errors) - Network dial errors (net.OpError - connection refused, DNS failures) - Terminal client errors (SASL auth failures) - Invalid cluster reference errors Add isNetworkDialError() helper using errors.As to find net.OpError in the error chain. Add unit tests covering various error wrapping scenarios (direct, single-wrapped, double-wrapped). Also adds operator.redpanda.com/allow-deletion annotation to force topic deletion even when broker connectivity issues exist. (cherry picked from commit 30cb82b) # Conflicts: # operator/internal/controller/redpanda/resource_controller.go
f0605d1 to
9002b8f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport
This will backport the following commits from
maintorelease/v25.1.x:Questions ?
Please refer to the Backport tool documentation