Control backup gc by completed and failed bakcups number
Signed-off-by: just1900 [email protected]
What problem does this PR solve?
fix #3660
What is changed and how does it work?
adding MaxCompletedBackups and MaxFailedBackups fields to control backup gc.
Code changes
- [x] Has Go code change
- [ ] Has CI related scripts change
Tests
- [ ] Unit test
- [ ] E2E test
- [ ] Manual test
- [ ] No code
Side effects
- [ ] Breaking backward compatibility
- [ ] Other side effects:
Related changes
- [ ] Need to cherry-pick to the release branch
- [ ] Need to update the documentation
Release Notes
Please refer to Release Notes Language Style Guide before writing the release note.
control backup gc by completed and failed bakcups number
[REVIEW NOTIFICATION]
This pull request has been approved by:
- KanShiori
- csuzhangxc
To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.
The full list of commands accepted by this bot can be found here.
Reviewer can indicate their review by submitting an approval review. Reviewer can cancel approval by submitting a request changes review.
Codecov Report
Merging #4480 (8a025a8) into master (0d13639) will increase coverage by
9.56%. The diff coverage is69.69%.
@@ Coverage Diff @@
## master #4480 +/- ##
==========================================
+ Coverage 62.79% 72.35% +9.56%
==========================================
Files 184 188 +4
Lines 19875 22310 +2435
==========================================
+ Hits 12480 16142 +3662
+ Misses 6262 5043 -1219
+ Partials 1133 1125 -8
| Flag | Coverage Δ | |
|---|---|---|
| e2e | 60.09% <0.00%> (?) |
|
| unittest | 62.80% <71.87%> (+0.01%) |
:arrow_up: |
seems like a issue exists when backupGCByPolicy and backupGCByMaxBackups concurrently delete backups.
/test pull-e2e-kind-serial
/test pull-e2e-kind pull-e2e-kind-br pull-e2e-kind-tngm
@just1900: PR needs rebase.
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.