openmetrics icon indicating copy to clipboard operation
openmetrics copied to clipboard

Add support for exemplars in Histograms and Counters

Open atheriel opened this issue 5 years ago • 0 comments

Exemplars are an optional feature of the OpenMetrics standard that attaches metadata about an individual sample to a histogram bucket, including its value, optional labels, and an optional timestamp:

foo_bucket{le="0.1"} 8 # {} 0.054
foo_bucket{le="1"} 10 # {id="9856e"} 0.67
foo_bucket{le="10"} 17 # {id="12fa8"} 9.8 1520879607.789

~Prometheus itself currently parses them but ignores their contents.~ Update: Prometheus now supports exemplars, as does Grafana.

Exemplar labels & their values should be capped at 128 characters, according to the Python client.

atheriel avatar Sep 01 '20 19:09 atheriel