Use the string representation of the labels instead of the hash

Signed-off-by: gotjosh <josue.abreu@gmail.com>
This commit is contained in:
gotjosh 2024-04-24 14:04:16 +01:00
parent 276201598c
commit fa75985c1c
No known key found for this signature in database
GPG key ID: A6E1DDE38FF3C74E

View file

@ -681,15 +681,15 @@ func (g *Group) RestoreForState(ts time.Time) {
continue
}
result := map[uint64]storage.Series{}
result := map[string]storage.Series{}
for sset.Next() {
result[sset.At().Labels().DropMetricName().Hash()] = sset.At()
result[sset.At().Labels().DropMetricName().String()] = sset.At()
}
alertRule.ForEachActiveAlert(func(a *Alert) {
var s storage.Series
s, ok := result[a.Labels.Hash()]
s, ok := result[a.Labels.String()]
if !ok {
return
}