We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c91490b commit 7b79e43Copy full SHA for 7b79e43
sdk/metric/exemplar/storage.go
@@ -40,6 +40,12 @@ func (r *storage) Collect(dest *[]Exemplar) {
40
*dest = reset(*dest, len(r.measurements), len(r.measurements))
41
var n int
42
for _, val := range r.measurements {
43
+ // For performance reasons, this iterates over measurements
44
+ // concurrently with new measurements being written. This means we do
45
+ // not get a point-in-time snapshot of the state of the reservoir.
46
+ // This means that for sequential Offer calls, a later Offer call may
47
+ // be collected and an earlier call not collected if they are written
48
+ // to different indices.
49
loaded := val.Load()
50
if loaded == nil {
51
continue
0 commit comments