mirror of
https://github.com/prometheus/prometheus.git
synced 2025-02-21 03:16:00 -08:00
Use the string representation of the labels instead of the hash
Signed-off-by: gotjosh <josue.abreu@gmail.com>
This commit is contained in:
parent
276201598c
commit
fa75985c1c
|
@ -681,15 +681,15 @@ func (g *Group) RestoreForState(ts time.Time) {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
result := map[uint64]storage.Series{}
|
result := map[string]storage.Series{}
|
||||||
for sset.Next() {
|
for sset.Next() {
|
||||||
result[sset.At().Labels().DropMetricName().Hash()] = sset.At()
|
result[sset.At().Labels().DropMetricName().String()] = sset.At()
|
||||||
}
|
}
|
||||||
|
|
||||||
alertRule.ForEachActiveAlert(func(a *Alert) {
|
alertRule.ForEachActiveAlert(func(a *Alert) {
|
||||||
var s storage.Series
|
var s storage.Series
|
||||||
|
|
||||||
s, ok := result[a.Labels.Hash()]
|
s, ok := result[a.Labels.String()]
|
||||||
if !ok {
|
if !ok {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue