-
Notifications
You must be signed in to change notification settings - Fork 39.2k
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
dra: enable adding ReservedFor entries through strategic-merge-patch #122276
Conversation
When moving the reservation of a claim for a pod into the PreBind phase in a future commit, multiple different update attempts will be executed concurrently. We want an attempt to succeed if and only if adding the entry passes validation. Without patch strategy and key, strategic-merge-patch replaces the entire ReservedFor instead of adding new entries. Server-side-apply cannot be used because each attempt may start with a stale ResourceClaim (thus cannot send the entire ReservedFor) and SSA doesn't support merging when using the same manager string. Using different managers (one for each entry) would work, but sounds like a bad hack.
Please note that we're already in Test Freeze for the Fast forwards are scheduled to happen every 6 hours, whereas the most recent run was: Tue Dec 12 10:21:04 UTC 2023. |
/triage accepted |
/lgtm |
LGTM label has been added. Git tree hash: 194c79fa6804a0e8a897a2beafa95db3453e02f6
|
/assign @msau42 For API approval. It's just a minor tweak which doesn't affect existing code, but blocks further work. |
This PR may require API review. If so, when the changes are ready, complete the pre-review checklist and request an API review. Status of requested reviews is tracked in the API Review project. |
/label api-review |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: apelisse, liggitt, pohly The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What type of PR is this?
/kind cleanup
/kind api-change
What this PR does / why we need it:
When moving the reservation of a claim for a pod into the PreBind phase in a future PR, multiple different update attempts will be executed concurrently. We want an attempt to succeed if and only if adding the entry passes validation. Without patch strategy and key, strategic-merge-patch replaces the entire ReservedFor instead of adding new entries.
Server-side-apply cannot be used because each attempt may start with a stale ResourceClaim (thus cannot send the entire ReservedFor) and SSA doesn't support merging when using the same manager string. Using different managers (one for each entry) would work, but sounds like a bad hack.
Which issue(s) this PR fixes:
Related-to: #113700
Special notes for your reviewer:
Does this PR introduce a user-facing change?
/assign @apelisse