I am trying to do something that sounds rather simple but failing to do so…
I have 2 jobs producing metrics under different names.
- job_one publishes metric_one (numeric)
- job_two publishes metrics_two (numeric)
Usually, only one of them runs, and the other is “NO DATA”.
As long as one of them is present and the value above X (say, 10
), I don’t want to alert.
So I setup 2 time series queries (A and B, one for each job) and tried different ways to alert, none worked:
- Classic condition:
A < 10 and B < 10
← alerts when either of them has no data, even if the other one meets the condition - Expression:
$A < 10 && $B < 10
← alerts when either of them has no data, even if the other one meets the condition - Expression
C = $A + $B
cannot be used in a classic condition ($C < 10
)
What’s the right way to have 2 series (one potentially not published, ie NO DATA) and alert only if none of them is at least 10
?