open-consul/agent/checks
Daniel Nephin 44d91ea56f
Add failures_before_warning to checks (#10969)
Signed-off-by: Jakub Sokołowski <jakub@status.im>

* agent: add failures_before_warning setting

The new setting allows users to specify the number of check failures
that have to happen before a service status us updated to be `warning`.
This allows for more visibility for detected issues without creating
alerts and pinging administrators. Unlike the previous behavior, which
caused the service status to not update until it reached the configured
`failures_before_critical` setting, now Consul updates the Web UI view
with the `warning` state and the output of the service check when
`failures_before_warning` is breached.

The default value of `FailuresBeforeWarning` is the same as the value of
`FailuresBeforeCritical`, which allows for retaining the previous default
behavior of not triggering a warning.

When `FailuresBeforeWarning` is set to a value higher than that of
`FailuresBeforeCritical it has no effect as `FailuresBeforeCritical`
takes precedence.

Resolves: https://github.com/hashicorp/consul/issues/10680

Signed-off-by: Jakub Sokołowski <jakub@status.im>

Co-authored-by: Jakub Sokołowski <jakub@status.im>
2021-09-14 12:47:52 -04:00
..
alias.go agent: ensure that most agent behavior correctly respects partition configuration (#10880) 2021-08-19 15:09:42 -05:00
alias_test.go testing: skip slow tests with -short 2020-12-07 13:42:55 -05:00
check.go Add failures_before_warning to checks (#10969) 2021-09-14 12:47:52 -04:00
check_test.go Add failures_before_warning to checks (#10969) 2021-09-14 12:47:52 -04:00
docker.go Sets tty in docker client back to true, as a potential fix for docker exec weirdness 2017-11-05 09:44:55 -06:00
docker_unix.go Decouple the code that executes checks from the agent 2017-10-25 11:18:07 +02:00
docker_windows.go Decouple the code that executes checks from the agent 2017-10-25 11:18:07 +02:00
grpc.go Return grpc serving status in health check errors 2020-09-22 21:16:58 +03:00
grpc_test.go Add failures_before_warning to checks (#10969) 2021-09-14 12:47:52 -04:00