fix(dataprotection): surface terminating namespace cleanup blocker#10693
Open
weicao wants to merge 3 commits into
Open
fix(dataprotection): surface terminating namespace cleanup blocker#10693weicao wants to merge 3 commits into
weicao wants to merge 3 commits into
Conversation
Collaborator
|
Auto Cherry-pick Instructions CLA Recheck Instructions |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #10693 +/- ##
==========================================
+ Coverage 63.98% 64.00% +0.02%
==========================================
Files 520 520
Lines 62995 63012 +17
==========================================
+ Hits 40305 40332 +27
+ Misses 19101 19080 -21
- Partials 3589 3600 +11
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
leon-ape
reviewed
Jul 20, 2026
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.
What problem does this PR solve?
When a Backup with
deletionPolicy: Deleteis deleted after its namespace has entered Terminating, DataProtection cannot create the worker resources needed to delete the backup files. The controller intentionally retains the finalizer and retries, but the Backup API has no durable indication of why deletion is blocked; the reason is visible only in controller logs.Fixes #10694.
What is changed and how does it work?
Backup.status.failureReasonTests
go test ./controllers/dataprotection -run 'TestDeleteBackupFiles(RecordsTerminatingNamespaceBlockerWithoutStoppingRetry|DoesNotRecordOrdinaryDeletingError|ReturnsStatusPatchError)$' -count=3KUBEBUILDER_ASSETS=... go test ./controllers/dataprotection -run TestAPIs -ginkgo.focus 'should not create worker resources when backup namespace is terminating' -count=1KUBEBUILDER_ASSETS=... go test ./controllers/dataprotection -count=1KUBEBUILDER_ASSETS=... go test ./pkg/dataprotection/backup -count=1go vet ./controllers/dataprotectionmake test-go-generate