-
Notifications
You must be signed in to change notification settings - Fork 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
Add support for rolebindings #1799
Conversation
cd5d803
to
c57ecbd
Compare
Co-authored-by: Manuel Rüger <manuel@rueg.eu>
/lgtm /hold |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: fpetkovski, kaitoii11, mrueg 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 |
@@ -27,6 +27,7 @@ var ( | |||
// DefaultResources represents the default set of resources in kube-state-metrics. | |||
DefaultResources = ResourceSet{ | |||
"certificatesigningrequests": struct{}{}, | |||
"clusterrolebindings": struct{}{}, |
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.
I wonder if we should really have these exposed by default. The use cases for this kind of metric seem really niche to me and I wouldn't want to add even more timeseries to the default setup if it is not really useful to the majority of ksm users. Same comment can be applied to the recently added role
and clusterrole
since they are not part of a release yet, we can still afford to remove them from the default if deemed meaningful.
Any thoughts on that @fpetkovski @mrueg?
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.
I think not exposing them by default makes sense. I agree that the amount of metrics has crept up over time and we can do a better job at providing sane defaults.
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.
sounds good to have standard set, should we resolve that in a follow-up PR since it will affect other resources as well?
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.
So for this PR, should I remove this line?
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.
No all good, we will continue in a follow up PR!
/hold cancel |
Thanks a lot for your contribution! |
What this PR does / why we need it:
Adds support for generating metrics for
clusterrolebindings
androlebindings
How does this change affect the cardinality of KSM: (increases, decreases or does not change cardinality)
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #1717