-
Notifications
You must be signed in to change notification settings - Fork 22
Open
Description
Describe the bug
Metrics gatherer seems to be returning raw CPU values instead of 0-100 for CPU utilization on resource-level metrics.
To Reproduce
Steps to reproduce the behavior:
When setting the following config:
kubernetesMetricSpecs:
- type: Resource
resource:
name: cpu
target:
type: Utilization
Metrics gatherer is returning the following:
"kubernetesMetrics": [
{
"current_replicas":1,
"spec": {
"type":"Resource"
},
"resource":{
"pod_metrics_info":{
"myapp-anonymized-123":{
"Timestamp":"2025-07-31T17:56:38Z",
"Window":59937000000,
"Value":4
}
}
}
}
]
This value seems like a discrepancy because I see 50% utilization (it's an 8m CPU request pod):
$ kubectl top pod myapp-anonymized-123
NAME CPU(cores) MEMORY(bytes)
myapp-anonymized-123 4m 37Mi
The kubectl reading seems to always line up with what is returned from metrics gatherer which makes it seem like it's only returning raw values
Expected behavior
A clear and concise description of what you expected to happen.
Metrics gatherer should return 50 (indicating 50% cpu util)
"kubernetesMetrics": [
{
"current_replicas":1,
"spec": {
"type":"Resource"
},
"resource":{
"pod_metrics_info":{
"myapp-anonymized-123":{
"Timestamp":"2025-07-31T17:56:38Z",
"Window":59937000000,
"Value":50
}
}
}
}
]
Kubernetes Details (kubectl version):
Kubernetes version, kubectl version etc.
v1.25.14
jthomperoo
Metadata
Metadata
Assignees
Labels
No labels