mirror of
https://github.com/prometheus/alertmanager
synced 2024-12-22 06:10:04 +00:00
b6851a5421
This fixes #559 by removing concurrent map writes to the matcher cache. The cache was guarded by the Silence's main lock, which only used a read-lock on queries. The cache's get methods lazily loads data into the cache and thus causing concurrent writes. We just change the main lock to always write-lock, as we don't expect high lock contention at this point and would have it in a dedicated cache lock anyway. |
||
---|---|---|
.. | ||
silencepb | ||
silence_test.go | ||
silence.go |