grafana/pkg/services/ngalert/state
Matthew Jacobson b9dc04139a
Alerting: Respect "For" Duration for NoData alerts (#65574)
* Alerting: Respect "For" Duration for NoData alerts

This change modifies `resultNoData` to be more inline with the logic of the other state handlers.

The main effects of this are:

1) NoData states with NoDataState config set to Alerting will respect "For" duration.
2) Prevents zero value in StartsAt and EndsAt for alerts that have only even been in normal state. This includes state transitions from NoDataState=OK and ExecErrState=OK.
3) Better state transition logging.
2023-03-31 19:05:15 +03:00
..
historian Alerting: Fix and re-enable filters instance labels in log line test (#65618) 2023-03-30 09:02:18 -05:00
template Alerting: Update prometheus version (#65688) 2023-03-31 16:34:35 +02:00
cache_test.go Phlare: Use enum config to send deduplicated func and filenames (#64435) 2023-03-13 11:06:04 +01:00
cache.go Alerting: Respect "For" Duration for NoData alerts (#65574) 2023-03-31 19:05:15 +03:00
image_mock.go Chore: Fix goimports grouping in alerting (#62424) 2023-01-30 09:55:35 +01:00
manager_bench_test.go Alerting: Expose Prometheus metrics for persisting state history (#63157) 2023-03-06 10:40:37 -06:00
manager_private_test.go Alerting: Do not persist noop transition from Normal state. (#61201) 2023-01-13 18:29:29 -05:00
manager_test.go Alerting: Respect "For" Duration for NoData alerts (#65574) 2023-03-31 19:05:15 +03:00
manager.go Alerting: Use logger with context in the state cache (#65663) 2023-03-31 10:11:30 -04:00
persist.go Chore: Remove result fields from ngalert (#65410) 2023-03-28 10:34:35 +02:00
state_test.go Chore: Remove xorcare/pointer dependency (#63900) 2023-03-06 05:23:15 -05:00
state.go Alerting: Respect "For" Duration for NoData alerts (#65574) 2023-03-31 19:05:15 +03:00
testing.go Chore: Remove result fields from ngalert (#65410) 2023-03-28 10:34:35 +02:00