Debian Codegraph @

sdk/metric/exemplar/exemplar.go

raw
1 // Copyright The OpenTelemetry Authors
2 // SPDX-License-Identifier: Apache-2.0
3
4 package exemplar // import "go.opentelemetry.io/otel/sdk/metric/exemplar"
5
6 import (
7 "time"
8
9 "go.opentelemetry.io/otel/attribute"
10 )
11
12 // Exemplar is a measurement sampled from a timeseries providing a typical
13 // example.
14 type Exemplar struct {
15 // FilteredAttributes are the attributes recorded with the measurement but
16 // filtered out of the timeseries' aggregated data.
17 FilteredAttributes []attribute.KeyValue
18 // Time is the time when the measurement was recorded.
19 Time time.Time
20 // Value is the measured value.
21 Value Value
22 // SpanID is the ID of the span that was active during the measurement. If
23 // no span was active or the span was not sampled this will be empty.
24 SpanID []byte `json:",omitempty"`
25 // TraceID is the ID of the trace the active span belonged to during the
26 // measurement. If no span was active or the span was not sampled this will
27 // be empty.
28 TraceID []byte `json:",omitempty"`
29 }