From b8808d59646b52c2f965d403a9422db7b1c5c57c Mon Sep 17 00:00:00 2001 From: bwplotka Date: Thu, 3 Jul 2025 12:40:57 +0100 Subject: [PATCH] model: add constants for type and unit labels. Useful to use e.g. in https://github.com/prometheus/prometheus/pull/16784 Signed-off-by: bwplotka --- model/labels.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/model/labels.go b/model/labels.go index de83afe93..e2ff83595 100644 --- a/model/labels.go +++ b/model/labels.go @@ -32,6 +32,12 @@ const ( // MetricNameLabel is the label name indicating the metric name of a // timeseries. MetricNameLabel = "__name__" + // MetricTypeLabel is the label name indicating the metric type of + // timeseries as per the PROM-39 proposal. + MetricTypeLabel = "__type__" + // MetricUnitLabel is the label name indicating the metric unit of + // timeseries as per the PROM-39 proposal. + MetricUnitLabel = "__unit__" // SchemeLabel is the name of the label that holds the scheme on which to // scrape a target.