Limit v1 webhooks to None and NoneOnDryRun side effects classes#81046
Limit v1 webhooks to None and NoneOnDryRun side effects classes#81046k8s-ci-robot merged 2 commits intokubernetes:masterfrom
Conversation
|
/sig api-machinery |
|
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. |
358641d to
8294313
Compare
8294313 to
0a37724
Compare
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: liggitt The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
|
||
| // SideEffects states whether this webhookk has side effects. | ||
| // Acceptable values are: Unknown, None, Some, NoneOnDryRun | ||
| // SideEffects states whether this webhook has side effects. |
There was a problem hiding this comment.
Would it be worth clarifying what happens when not specified (can it, and should we default it)?
There was a problem hiding this comment.
it cannot be omitted in v1. it's required and not defaulted
There was a problem hiding this comment.
AFAIU, the distinction between None and NoneOnDryRun makes no difference, so I'm not really sure why we force people to specify a field that adds no value?
There was a problem hiding this comment.
making it explicit in v1 ensures all manifests ack that no side effects are allowed. the distinction between None and NoneOnDryRun doesn't matter for the dispatcher, but allows expressing that there is a difference in behavior specifically for dry run
|
/lgtm |
What type of PR is this?
/kind api-change
/kind feature
What this PR does / why we need it:
Requires admission webhooks registered via v1 to not have side effects (only
NoneandNoneOnDryRunare allowed as side effects classes)Which issue(s) this PR fixes:
Fixes #68839
Does this PR introduce a user-facing change?:
(will add to v1 promotion PR release note in #79549)