-
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
feat: Add label about metric selector for kube_horizontalpodautoscaler_(spec/status)_target_metric #2186
Conversation
…c/status)_target_metric
/assign |
QQ: are these two metrics the same or different? In thinking whether we need this label or not. |
For example, hpa can autoscale based on the number of http requests. But if you want to be more accurate, for example, setting different thresholds for requests with url=/api/v1/blog and url=/api/v1/car, then we usually will not set different metric names for them, but the same metric with different labels. (e.g. http_requests_per_minute{method="get",url="/api/v1/blog"}) and http_requests_per_minute{method="get",url="/api/v1/car"}) Another example: task production and consumption model. For example, there are multiple types of tasks in message queue. We usually use labels to distinguish the types of these tasks, rather than metrics with different names. (e.g. task_queue_pending_total{taskType="write"}) and task_queue_pending_total{taskType="read"}) |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: whitebear009 The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Hi, How do you think for it? @CatherineF-dev @dgrisonnet |
@dgrisonnet Hello, how can I promote this pr ? |
The Kubernetes project currently lacks enough contributors to adequately respond to all PRs. This bot triages PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
The Kubernetes project currently lacks enough active contributors to adequately respond to all PRs. This bot triages PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle rotten |
The Kubernetes project currently lacks enough active contributors to adequately respond to all issues and PRs. This bot triages PRs according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /close |
@k8s-triage-robot: Closed this PR. In response to this:
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. |
What this PR does / why we need it:
Currently, the indicator kube_horizontalpodautoscaler_spec_target_metric/kube_horizontalpodautoscaler_status_target_metric does not expose the metric selector field.
If there is an hpa object, which has two metrics with the same name but different selectors, the results will only display one of them.
How does this change affect the cardinality of KSM: (increases, decreases or does not change cardinality)
increases
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 #