grafana/pkg/services/alerting/interfaces.go

26 lines
381 B
Go
Raw Normal View History

package alerting
import (
"time"
)
2016-07-27 09:29:28 -05:00
type EvalHandler interface {
Eval(context *EvalContext)
}
type Scheduler interface {
2016-07-27 09:29:28 -05:00
Tick(time time.Time, execQueue chan *Job)
Update(rules []*Rule)
}
type Notifier interface {
2016-07-27 09:29:28 -05:00
Notify(alertResult *EvalContext)
GetType() string
NeedsImage() bool
2016-09-13 08:09:55 -05:00
PassesFilter(rule *Rule) bool
}
2016-07-27 09:29:28 -05:00
type Condition interface {
Eval(result *EvalContext)
}