Skip to content

Commit acd01d9

Browse files
committed
tmp
Signed-off-by: bwplotka <bwplotka@gmail.com>
1 parent 08fa023 commit acd01d9

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

docs/specs/om/open_metrics_spec_2_0.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@ Labels are key-value pairs consisting of strings.
113113

114114
Label names beginning with two underscores are RESERVED and MUST NOT be used unless specified by this standard. Such Label names MAY be used in place of TYPE and UNIT metadata in cases where MetricFamilies' metadata might otherwise be conflicting, such as metric federation cases.
115115

116+
// MAYBE: Link to where we explain "UTF-8 metrics may reduce usability"
116117
Label names SHOULD follow the restrictions in the ABNF section under the `label-name` section. Label names MAY be any quoted escaped UTF-8 string as described in the ABNF section. Be aware that exposing UTF-8 metrics may reduce usability.
117118

118119
Empty label values SHOULD be treated as if the label was not present.
@@ -121,26 +122,30 @@ Empty label values SHOULD be treated as if the label was not present.
121122

122123
A LabelSet MUST consist of Labels and MAY be empty. Label names MUST be unique within a LabelSet.
123124

125+
// TODO(dashpole): Sample
124126
#### MetricPoint
125127

128+
// TODO(dashpole): Updating... (removed)
126129
Each MetricPoint consists of a set of values, depending on the MetricFamily Type.
127130

128131
#### Exemplars
129132

130133
Exemplars are references to data outside of the MetricSet. A common use case are IDs of program traces.
131134

132-
Exemplars MUST consist of a LabelSet and a value, and MUST have a timestamp. The LabelSet SHOULD NOT contain any Label names included in the MetricPoint's LabelSet. The timestamp SHOULD NOT be after the MetricPoint's timestamp, if present, and SHOULD NOT be before the MetricPoint's start timestamp, if present.
135+
Exemplars MUST consist of a LabelSet and a Number value, and MUST have a timestamp. The LabelSet SHOULD NOT contain any Label names included in the MetricPoint's LabelSet. The timestamp SHOULD be before or equal to the MetricPoint's timestamp, if present. The timestamp SHOULD be after or equal to the MetricPoint's start timestamp, if present.
133136

134-
The Exemplar's timestamp SHOULD be close to the point in time when the referenced data was created, but doesn't have to be exact. For example if getting an exact timestamp is costly, it is acceptable to use some external source or synthetic clock.
137+
The Exemplar's timestamp SHOULD be close to the point when it was observed, but doesn't have to be exact. For example, if getting an exact timestamp is costly, it is acceptable to use some external source or an estimate.
135138

136139
When an exemplar references a [Trace Context](https://www.w3.org/TR/trace-context-2/), it SHOULD use the `trace_id` key for the [trace-id](https://www.w3.org/TR/trace-context-2/#traceparent-header) field, and the `span_id` key for the [`parent-id`](https://www.w3.org/TR/trace-context-2/#traceparent-header) field.
137140

138141
While there's no [hard limit](#size-limits) specified, Exemplar's LabelSet SHOULD NOT be used to transport large data like tracing span details or other event logging.
139142

143+
// TODO: "If you truncate data try to preserve trace id and span id"
140144
Ingestors MAY truncate the Exemplar's LabelSet or discard Exemplars.
141145

142146
#### Metric
143147

148+
// TODO(dashpole) updating
144149
Metrics are defined by a unique LabelSet within a MetricFamily. Metrics MUST contain a list of one or more MetricPoints. Metrics with the same name for a given MetricFamily SHOULD have the same set of label names in their LabelSet.
145150

146151
MetricPoints SHOULD NOT have explicit timestamps.

0 commit comments

Comments
 (0)