Alerting: Fix stale values associated with states that have gone to NoData, unify values calculation (#89807)
* Unify values * Fix with latest changes on main * Fix up NaN test * Keep refIDs with -1 as value * Test that refIDs are preserved on Normal to Error transition * Alerting to err test too * Add a blurb to docs about this behavior
This commit is contained in:
@@ -80,6 +80,12 @@ func WithLabels(labels data.Labels) ResultMutator {
|
||||
}
|
||||
}
|
||||
|
||||
func WithValues(values map[string]NumberValueCapture) ResultMutator {
|
||||
return func(r *Result) {
|
||||
r.Values = values
|
||||
}
|
||||
}
|
||||
|
||||
type FakeLoadedMetricsReader struct {
|
||||
fingerprints map[data.Fingerprint]struct{}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user