Skip to content

Commit d4622dc

Browse files
committed
Improve watchdog alert
This expression fires the Watchdog alert also if the TSDB is up to date and therefore checks the functionality of the full stack. With `vector(1)`, only alertmanager needs to be functional to fire. So In case of a full TSDB storage, the Watchdog still fires and the lack of new metrics goes unnoticed. Signed-off-by: Andreas Tellenbach <andreas.tellenbach@gmail.com>
1 parent defa2bd commit d4622dc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

jsonnet/kube-prometheus/components/mixin/alerts/general.libsonnet

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"DeadMansSnitch" integration in PagerDuty.
2929
|||,
3030
},
31-
expr: 'vector(1)',
31+
expr: 'present_over_time(prometheus_tsdb_head_max_time[1m]) != 0',
3232
labels: {
3333
severity: 'none',
3434
},

0 commit comments

Comments
 (0)