Alerting: Add database table for persisting alerting configuration (#32042)

* Alerting: Add database table for persisting alerting configuration

* Fix the linter

* Address review comments

* Don't split templates and configuration

It is already bundled together as part of a of the API so might as well
marshall it directly.
This commit is contained in:
gotjosh
2021-03-18 18:12:28 +00:00
committed by GitHub
parent 6c7f0fece8
commit cc74b1fe46
5 changed files with 73 additions and 0 deletions

View File

@@ -35,6 +35,9 @@ type Store interface {
SaveAlertInstance(cmd *models.SaveAlertInstanceCommand) error
ValidateAlertDefinition(*models.AlertDefinition, bool) error
UpdateAlertDefinitionPaused(*models.UpdateAlertDefinitionPausedCommand) error
// Alertmanager
GetLatestAlertmanagerConfiguration(cmd *models.GetLatestAlertmanagerConfigurationQuery) error
}
// DBstore stores the alert definitions and instances in the database.