Code refactoring for bpa operator
[icn.git] / cmd / bpa-operator / vendor / go.opencensus.io / metric / metricdata / exemplar.go
1 // Copyright 2018, OpenCensus Authors
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 //     http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14
15 package metricdata
16
17 import (
18         "time"
19 )
20
21 // Exemplar is an example data point associated with each bucket of a
22 // distribution type aggregation.
23 //
24 // Their purpose is to provide an example of the kind of thing
25 // (request, RPC, trace span, etc.) that resulted in that measurement.
26 type Exemplar struct {
27         Value       float64     // the value that was recorded
28         Timestamp   time.Time   // the time the value was recorded
29         Attachments Attachments // attachments (if any)
30 }
31
32 // Attachments is a map of extra values associated with a recorded data point.
33 type Attachments map[string]interface{}