Skip to content

Conversation

succa
Copy link
Contributor

@succa succa commented Apr 15, 2025

Copy link

linux-foundation-easycla bot commented Apr 15, 2025

CLA Signed


The committers listed above are authorized under a signed CLA.

@k8s-ci-robot k8s-ci-robot added area/api cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Apr 15, 2025
@k8s-ci-robot
Copy link
Contributor

Hi @succa. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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-sigs/prow repository.

@succa succa force-pushed the feature/goaway-chance-apiserver branch from afc1136 to a34496a Compare April 15, 2025 13:05
@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Apr 15, 2025
@@ -470,6 +470,8 @@ type KubeAPIServerConfig struct {
RequestheaderAllowedNames []string `json:"requestheaderAllowedNames,omitempty" flag:"requestheader-allowed-names"`
// FeatureGates is set of key=value pairs that describe feature gates for alpha/experimental features.
FeatureGates map[string]string `json:"featureGates,omitempty" flag:"feature-gates"`
// GoawayChance is the probability that send a GOAWAY to HTTP/2 clients. Default to 0, means never send GOAWAY. Max is 0.02 to prevent break the apiserver.
GoawayChance string `json:"goawayChance,omitempty" flag:"goaway-chance"`
Copy link
Member

Choose a reason for hiding this comment

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

This seems to be defined as float64:
https://github.com/kubernetes/kubernetes/blob/b53b9fb5573323484af9a19cf3f5bfe80760abba/staging/src/k8s.io/apiserver/pkg/server/config.go#L266

Suggested change
GoawayChance string `json:"goawayChance,omitempty" flag:"goaway-chance"`
GoawayChance float64 `json:"goawayChance,omitempty" flag:"goaway-chance"`

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Correct, but controller-gen apparently does not like float64. When setting it, the output is
found float, the usage of which is highly discouraged, as support for them varies across languages. Please consider serializing your float as string instead. If you are really sure you want to use them, re-run with crd:allowDangerousTypes=true

Please suggest if the flag crd:allowDangerousTypes=true can be added

Copy link
Member

Choose a reason for hiding this comment

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

Thanks for the explanation. One more Q, how far would you like this flag to be backported?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not sure about the question, following the docs I updated v1alpha2 and v1alpha3 as well. We are currently using v1alpha2, so ideally the flag should be present in all Cluster versions

@hakman
Copy link
Member

hakman commented Apr 22, 2025

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Apr 22, 2025
@hakman
Copy link
Member

hakman commented Apr 22, 2025

/retest

Copy link
Member

@hakman hakman left a comment

Choose a reason for hiding this comment

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

Thanks @succa! 🙂

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

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hakman

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

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 23, 2025
@hakman
Copy link
Member

hakman commented Apr 23, 2025

/retest

k8s-ci-robot added a commit that referenced this pull request Apr 23, 2025
…-upstream-release-1.32

Automated cherry pick of #17357: add goaway-chance parameter for kube-apiserver
@k8s-ci-robot k8s-ci-robot merged commit 732397b into kubernetes:master Apr 23, 2025
25 checks passed
k8s-ci-robot added a commit that referenced this pull request Apr 23, 2025
…-upstream-release-1.31

Automated cherry pick of #17357: add goaway-chance parameter for kube-apiserver
@k8s-ci-robot k8s-ci-robot added this to the v1.32 milestone Apr 23, 2025
k8s-ci-robot added a commit that referenced this pull request Apr 23, 2025
…-upstream-release-1.30

Automated cherry pick of #17357: add goaway-chance parameter for kube-apiserver
@rifelpet rifelpet modified the milestones: v1.32, v1.33 Jun 23, 2025
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/api cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants