mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
If the db already has an entry in the kvstore for the silences of an alertmanager before the migration has taken place, then it's possible that the active alertmanager will overwrite the silence file created by the migration before it has a chance to load it into memory. This should not happen normally but is possible in edge-cases. This change opts to bypass the unnecessary step of writing the silences to disk during the migration and instead write them directly to the kvstore. This avoids the race condition entirely and is more correct as we treat the database as the source of truth for AM state.
This directory contains the code for the Grafana backend.
The contributor documentation for Grafana's backend is in /contribute/backend/README.md.