Alerting: Log expression command types during evaluation (#84614)

This commit is contained in:
Yuri Tseretyan
2024-03-19 10:00:03 -04:00
committed by GitHub
parent 09817e2c7f
commit 9dc4221508
11 changed files with 101 additions and 0 deletions
+4
View File
@@ -128,6 +128,10 @@ func (tc *ThresholdCommand) Execute(ctx context.Context, now time.Time, vars mat
return mathCommand.Execute(ctx, now, vars, tracer)
}
func (tc *ThresholdCommand) Type() string {
return TypeThreshold.String()
}
// createMathExpression converts all the info we have about a "threshold" expression in to a Math expression
func createMathExpression(referenceVar string, thresholdFunc ThresholdType, args []float64, invert bool) (string, error) {
var exp string