Skip to content
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

Lock ServerSideApply feature to true #112748

Merged
merged 1 commit into from Sep 27, 2022

Conversation

wojtek-t
Copy link
Member

@wojtek-t wojtek-t commented Sep 27, 2022

Ref #110173 (comment)

Lock ServerSideApply feature gate to true with the feature already being GA.

/kind cleanup
/priority important-soon
/sig api-machinery

/assign @apelisse @liggitt

@k8s-ci-robot k8s-ci-robot added the release-note-none Denotes a PR that doesn't merit a release note. label Sep 27, 2022
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Sep 27, 2022
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. area/apiserver area/test sig/apps Categorizes an issue or PR as relevant to SIG Apps. sig/instrumentation Categorizes an issue or PR as relevant to SIG Instrumentation. sig/testing Categorizes an issue or PR as relevant to SIG Testing. labels Sep 27, 2022
@wojtek-t wojtek-t force-pushed the lock_ssa_gate branch 4 times, most recently from f8c35e3 to 718fe22 Compare September 27, 2022 10:39
@liggitt
Copy link
Member

liggitt commented Sep 27, 2022

lgtm, will let @apelisse tag

Copy link
Member

@apelisse apelisse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So this keeps the feature-gate but basically ignores its value throughout? Shouldn't we at least warn people that the feature-gate is moot?

/lgtm
/approve

@@ -599,7 +599,7 @@ func (a *APIInstaller) registerResourceHandlers(path string, storage rest.Storag
if a.group.MetaGroupVersion != nil {
reqScope.MetaGroupVersion = *a.group.MetaGroupVersion
}
if a.group.OpenAPIModels != nil && utilfeature.DefaultFeatureGate.Enabled(features.ServerSideApply) {
if a.group.OpenAPIModels != nil {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not necessarily in this pull-request, but I think we need to remove that condition. the scope.FieldManager should always be set otherwise the handler is going to crash later when it's used, which is a worse experience.

If this causes flakiness due to extra memory-allocation, @alexzielenski fix for swagger unmarshaling will almost certainly solve the problem.

cc @Jefftree

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ack, I'll work on removing the OpenAPI conditions

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Sep 27, 2022
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: apelisse, wojtek-t

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@Jefftree
Copy link
Member

Are we able to remove the feature gate without it being locked to default first?

@k8s-ci-robot k8s-ci-robot merged commit 97d37c2 into kubernetes:master Sep 27, 2022
@k8s-ci-robot k8s-ci-robot added this to the v1.26 milestone Sep 27, 2022
@fedebongio
Copy link
Contributor

/triage accepted

@k8s-ci-robot k8s-ci-robot added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Sep 27, 2022
@wojtek-t
Copy link
Member Author

So this keeps the feature-gate but basically ignores its value throughout? Shouldn't we at least warn people that the feature-gate is moot?

It's what we do with pretty much any other feature gate.
Re warning people - let me add a release note - good point.

@k8s-ci-robot k8s-ci-robot added release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed release-note-none Denotes a PR that doesn't merit a release note. labels Sep 28, 2022
@apelisse
Copy link
Member

It's what we do with pretty much any other feature gate.

I don't think it'd hurt to have something in the boot sequence that does:

if !utilfeature.DefaultFeatureGate.Enabled(features.ServerSideApply) {
     log.Warn("Server-Side Apply is GA and can not be disabled.")
}

or something?

@liggitt
Copy link
Member

liggitt commented Sep 28, 2022

if !utilfeature.DefaultFeatureGate.Enabled(features.ServerSideApply) {

LockToDefault: true already automatically errors/exits with a message like that if you try to set --feature-gates=ServerSideApply=false

@apelisse
Copy link
Member

OK Thanks, I missed that, perfect :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/apiserver area/test cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/api-machinery Categorizes an issue or PR as relevant to SIG API Machinery. sig/apps Categorizes an issue or PR as relevant to SIG Apps. sig/instrumentation Categorizes an issue or PR as relevant to SIG Instrumentation. sig/testing Categorizes an issue or PR as relevant to SIG Testing. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants