Hi I have the following tick:
dbrp “statsd”.“shortterm”
stream
|from()
.measurement('memory_percent_free')
.groupBy('host')
|window()
.period(10m)
.every(1m)
|mean('value')
|alert()
.message('{{ .Level}}: {{ .Name }}/{{ index .Tags "host" }} has high cpu load: {{ index .Fields "mean" }}')
.warn(lambda: sigma("mean") > 2.0)
.crit(lambda: sigma("mean") > 3.0)
.log('/tmp/kap.log')
.slack()
How would i go about using state duration with this tick i.e. i want alert when sigma("mean) > 2.0 for 5 minutes.
thanks !
rr