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
kube-aggregator/openapi/controller: remove trailing 1 in failure ratelimiter #77979
Conversation
/lgtm from instrumentation side, let's have one of the approvers confirm that this number isn't there for a reason, but it looks strange at best. |
/assign @logicalhan |
/assign @roycaihw |
/hold before we merge this, just to verify if the name is exposed in metrics and if changing it will cause any breaking change |
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.
Renaming a metric is equivalent to deleting a metric and creating a new one. We should probably deprecate the old metric so that if people are using it, they have some window to migrate off of it. Also, if we're going to do this, we should really just completely fix the name of the metric (i.e. no camel-casing at all).
This is renaming a single label value, not the metric name, nor the label-key. I don’t know whether deprecation is necessary here as it’s more a time series identity label rather than one you would actively query and for what it’s worth the underlying metrics were broken until @s-urbaniak recently fixed them (the PR may still be open in which case they are still broken). |
It is used to construct a number of different metric names:
|
Thanks, I didn’t see that while browsing the code. That’s unfortunate. In that case I agree this should be changed to snake case and remove the trailing number. In regards to deprecation I think these metrics violate just about every guideline we have and I can’t find any usages in the popular sources. I think just changing would be ok. |
@logicalhan @brancz thanks for verifying the bigger picture! It seems we have a consensus to a) convert this to snake case and b) omit deprecation. I am pushing a commit on top of this then. |
fwiw I did a quick sweep and verified we have more camel-case occurences: kubernetes/staging/src/k8s.io/kube-aggregator/pkg/apiserver/apiservice_controller.go Line 62 in afd928b
kubernetes/pkg/controller/clusterroleaggregation/clusterroleaggregation_controller.go Line 58 in afd928b
Line 62 in 3b618af
kubernetes/staging/src/k8s.io/kube-aggregator/pkg/controllers/status/available_controller.go Lines 96 to 101 in f9e1620
Line 55 in 42f23bd
Finally the sample controller includes a camel case example which we probably should also fix along with a comment:
I can grep to check if those are in general use and submit another cleanup PR fixing the above. |
a7201f9
to
83b850c
Compare
/remove-lifecycle rotten |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: brancz, s-urbaniak, sttts 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 |
/test all |
/retest Review the full test history for this PR. Silence the bot with an |
21 similar comments
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
/retest Review the full test history for this PR. Silence the bot with an |
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
This removes a trailing 1 from the rate limiting name as it was confusing, and also appears in metrics.
Which issue(s) this PR fixes:
Special notes for your reviewer:
Does this PR introduce a user-facing change?: