mirror of
https://github.com/grafana/grafana.git
synced 2025-01-16 19:52:33 -06:00
daabf64aa1
* Update scheduler * Fix tests * Fixes after code review feedback * lint - add uncommitted modifications Co-authored-by: kyle <kyle@grafana.com>
16 lines
354 B
Go
16 lines
354 B
Go
package schedule
|
|
|
|
import (
|
|
"github.com/grafana/grafana/pkg/services/ngalert/models"
|
|
)
|
|
|
|
func (sch *schedule) fetchAllDetails() []*models.AlertRule {
|
|
q := models.ListAlertRulesQuery{}
|
|
err := sch.ruleStore.GetAlertRulesForScheduling(&q)
|
|
if err != nil {
|
|
sch.log.Error("failed to fetch alert definitions", "err", err)
|
|
return nil
|
|
}
|
|
return q.Result
|
|
}
|