Alerting: Make orgID a direct arg of writer interface (#91422)

make orgID a direct arg of writer interface
This commit is contained in:
Alexander Weaver
2024-08-02 09:37:28 -05:00
committed by GitHub
parent 6f6a06435d
commit 72ecde5045
6 changed files with 12 additions and 18 deletions
@@ -257,7 +257,7 @@ func (r *recordingRule) tryEvaluation(ctx context.Context, ev *Evaluation, logge
}
writeStart := r.clock.Now()
err = r.writer.Write(ctx, ev.rule.Record.Metric, ev.scheduledAt, frames, ev.rule.Labels)
err = r.writer.Write(ctx, ev.rule.Record.Metric, ev.scheduledAt, frames, ev.rule.OrgID, ev.rule.Labels)
writeDur := r.clock.Now().Sub(writeStart)
if err != nil {
+1 -1
View File
@@ -49,7 +49,7 @@ type RulesStore interface {
}
type RecordingWriter interface {
Write(ctx context.Context, name string, t time.Time, frames data.Frames, extraLabels map[string]string) error
Write(ctx context.Context, name string, t time.Time, frames data.Frames, orgID int64, extraLabels map[string]string) error
}
type schedule struct {