Skip to content
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_service_labels metric has inconsistent label dimensions #192

Closed
cofyc opened this issue Aug 1, 2017 · 3 comments · Fixed by #194
Closed

kube_service_labels metric has inconsistent label dimensions #192

cofyc opened this issue Aug 1, 2017 · 3 comments · Fixed by #194
Assignees

Comments

@cofyc
Copy link
Member

cofyc commented Aug 1, 2017

Hi, guys

In recent commit 1f8761d, prometheus client_go library is updated, it checks inconsistent label dimensions now, /metrics will report following errors (test against kubernetes ./hack/local-up-cluster.sh):

# curl -s http://localhost:8081/metrics
An error has occurred during metrics gathering:

collected metric kube_service_labels label:<name:"label_addonmanager_kubernetes_io_mode" value:"Reconcile" > label:<name:"label_k8s_app" value:"kube-dns" > label:<name:"label_kubernetes_io_cluster_service" value:"true" > label:<name:"label_kubernetes_io_name" value:"KubeDNS" > label:<name:"namespace" value:"kube-system" > label:<name:"service" value:"kube-dns" > gauge:<value:1 >  has label dimensions inconsistent with previously collected metrics in the same metric family

I checked the previous version of prometheus client_go library, found that checkMetricConsistency function (which is used to check inconsistent label) is disabled (b12f83d).

Should we change kube_service_labels metric to have consistent label dimension or update current prometheus client_go library to disable checkMetricConsistency functionality?

@cofyc cofyc changed the title kube_service_labels metrics has inconsistent label dimensions kube_service_labels metric has inconsistent label dimensions Aug 1, 2017
@matthiasr
Copy link

I think for this particular metric we need to disable it. Labels are necessarily inconsistent between Kubernetes objects, even of the same kind. Is it possible to disable this check just for the _labels metrics?

@matthiasr
Copy link

As a hotfix I think we should disable it wholesale to unbreak things.

@brancz
Copy link
Member

brancz commented Aug 1, 2017

Yes this was my bad, I should have caught it when reviewing. We previously disabled this check manually. I'll get right to it. Thanks a lot for reporting!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants