feat(kube-eagle): Add pod labels to metrics#34
feat(kube-eagle): Add pod labels to metrics#34Prayer3th wants to merge 1 commit intocloudworkz:masterfrom
Conversation
Prayer3th
commented
Sep 3, 2020
- Add label information for each pod-related metrics
|
This PR adds a single label with the concatenated labels from the scraped pods. I'm not entirely sure if and how it's possible but the feature request and my personal preference is having separated labels instead, see: #7 When all nodes in your Kubernetes cluster have a label: |
|
I understand what you mean, separate labels are indeed more beautiful and more readable. However, if there is a duplicate label (the same key but different value) in the extra label that is exposed by kube-eagle itself, then one label will be overwritten. |
|
This is a valid concern, we could prefix the label_names though (e.g. with |
|
I think your idea is very good, but I encountered another problem during the coding process: the key of each pod label is different, but prometheus seems unable to define dynamic labels. So I think it is more feasible to use the "labels" key to solidify all indicators. When extracting the label, you only need to cut according to the space to get the required data without too much extra work. |
|
Any updates? |