Display metric label value in single stat panel
Problem to solve
I want to be able to display a metric label value (instead of the metric value) in a single stat panel.
For example, given the following metric:
prometheus_build_info{branch="HEAD",goversion="go1.12.8",instance="localhost:9090",job="prometheus",revision="43acd0e2e93f9f70c49b2267efa0124f1e759e86",version="2.12.0"} 1
I want to display the value of the goversion
label in the single stat panel. So, go1.12.8
would be displayed as the panel value.
Intended users
User experience goal
Proposal
Further details
It is a common pattern to have a Prometheus metric with a token value (such as 1
), but whose labels hold important information. This feature will be useful for displaying information from such metrics.
Permissions and Security
Documentation
Availability & Testing
- backend and frontend unit and integration tests
- covered on E2E test for different types of panels for dashboards
What does success look like, and how can we measure that?
Edited by Sofia Vistas