mirror of
https://github.com/coredns/coredns.git
synced 2026-10-26 20:25:43 -04:00
plugin/forward: add startup health checks with start_failed (#8663)
* plugin/forward: add startup health checks with start_failed Signed-off-by: houyuwushang <180804215+houyuwushang@users.noreply.github.com> * test: separate CoreDNS and third-party imports Signed-off-by: houyuwushang <180804215+houyuwushang@users.noreply.github.com> --------- Signed-off-by: houyuwushang <180804215+houyuwushang@users.noreply.github.com>
This commit is contained in:
@@ -57,6 +57,7 @@ forward FROM TO... {
|
||||
tls_servername NAME
|
||||
policy random|round_robin|sequential
|
||||
health_check DURATION [no_rec] [domain FQDN]
|
||||
start_failed
|
||||
max_concurrent MAX
|
||||
next RCODE_1 [RCODE_2] [RCODE_3...]
|
||||
failfast_all_unhealthy_upstreams
|
||||
@@ -77,6 +78,12 @@ forward FROM TO... {
|
||||
* `max_fails` is the number of subsequent failed health checks that are needed before considering
|
||||
an upstream to be down. If 0, the upstream will never be marked as down (nor health checked).
|
||||
Default is 2.
|
||||
* `start_failed` starts upstreams in an unhealthy state and immediately runs health checks using
|
||||
the configured `health_check` settings. Each upstream becomes healthy after its first successful
|
||||
check. This option is disabled by default and cannot be combined with `max_fails 0`.
|
||||
Checks run asynchronously; startup does not wait for them. While all upstreams are unhealthy,
|
||||
requests follow the usual all-unhealthy policy. Combine with `failfast_all_unhealthy_upstreams`
|
||||
to return SERVFAIL until an upstream passes a check instead of trying a random upstream.
|
||||
* `max_connect_attempts` caps the total number of upstream connect attempts
|
||||
performed for a single incoming DNS request. The default cap is twice the number of
|
||||
configured upstreams, allowing two complete passes when all upstreams are healthy.
|
||||
|
||||
Reference in New Issue
Block a user