notifications: read without tran, write with tran

This commit is contained in:
bergquist
2018-06-29 15:15:31 +02:00
parent 8ff538be07
commit 396f8e6464
6 changed files with 16 additions and 10 deletions

View File

@@ -1,6 +1,9 @@
package alerting
import "time"
import (
"context"
"time"
)
type EvalHandler interface {
Eval(evalContext *EvalContext)
@@ -17,7 +20,7 @@ type Notifier interface {
NeedsImage() bool
// ShouldNotify checks this evaluation should send an alert notification
ShouldNotify(evalContext *EvalContext) bool
ShouldNotify(ctx context.Context, evalContext *EvalContext) bool
GetNotifierId() int64
GetIsDefault() bool