mirror of
https://github.com/prometheus/prometheus.git
synced 2025-01-11 05:47:27 -08:00
Revert "Fix race condition in Rule manager.Update() function"
This reverts commit 8b11d2cfb6
.
Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
This commit is contained in:
parent
babadf13e8
commit
2051ae2e6a
|
@ -921,7 +921,7 @@ func (m *Manager) Update(interval time.Duration, files []string, externalLabels
|
||||||
}
|
}
|
||||||
|
|
||||||
wg.Add(1)
|
wg.Add(1)
|
||||||
go func(newg *Group, oldg *Group) {
|
go func(newg *Group) {
|
||||||
if ok {
|
if ok {
|
||||||
oldg.stop()
|
oldg.stop()
|
||||||
newg.CopyState(oldg)
|
newg.CopyState(oldg)
|
||||||
|
@ -934,7 +934,7 @@ func (m *Manager) Update(interval time.Duration, files []string, externalLabels
|
||||||
newg.run(m.opts.Context)
|
newg.run(m.opts.Context)
|
||||||
}()
|
}()
|
||||||
wg.Done()
|
wg.Done()
|
||||||
}(newg, oldg)
|
}(newg)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Stop remaining old groups.
|
// Stop remaining old groups.
|
||||||
|
|
Loading…
Reference in a new issue