-
Notifications
You must be signed in to change notification settings - Fork 1.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
Guard PodSpec dry run with a feature flag #8276
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@whaught: 0 warnings.
In response to this:
Fixes #8077
Proposed Changes
- Guard the PodSpec dry run feature with a feature flag
Release Note
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.
/assign @JRBANCEL |
Apart from the flag naming |
/hold while I sync with @JRBANCEL on how we want to name these |
/assign @dprotaso |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it make sense to have a flag for enabled
and make the default behaviour for dryrun as disabled in this case? It would eliminate the need for enabled and disabled flags.
We want to provide control to the operator. A cluster operator should be able to disable features entirely, or at least require the developers to manually enable it (that's what |
The following jobs failed:
Failed non-flaky tests preventing automatic retry of pull-knative-serving-unit-tests:
and 37 more. |
/approve |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dprotaso, JRBANCEL, whaught 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 |
The following is the coverage report on the affected files.
|
case config.Disabled: | ||
return nil | ||
default: | ||
mode = DryRunMode(uns.GetAnnotations()[PodSpecDryRunAnnotation]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be same as disabled if annotation is not set?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The feature is only client controlled by the annotation in "allowed" mode. Vendors may disable the feature completely or always run it with disable/allowed feature flags.
case config.Enabled: | ||
mode = DryRunEnabled | ||
case config.Disabled: | ||
return nil |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this right though? This basically skips the whole validation?
I'd expect disable means we don't use dry run to validate the template.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At the moment dryrun is the only validation in this codepath, but we'd want to rearrange this if we had other validations here
/hold cancel |
Fixes #8077
Proposed Changes
Release Note