mirror of
https://github.com/coredns/coredns.git
synced 2025-12-03 17:14:05 -05:00
Add configuration flag to set if RecursionDesired should be set on health checkers in Forward-plugin (#3679)
* Make the RD-flag in health-checks in the Forward-plugin configurable Introduces a new configuration flag; `health_check_non_recursive`. This flag makes the health-checker do non-recursive requests when checking the health of upstream servers. Signed-off-by: Geir Haugom <ghagit@haugom.org> Signed-off-by: Christian Tryti <ctryti@gmail.com> * Changes after feedback from reviewer * Better tests of health-checks with and without recursion * Removed the health_check_non_recursive configuration in favor of extending the existing health_check configuration. Now supports an optional `no_rec` argument. Signed-off-by: Christian Tryti <ctryti@gmail.com> * Add new test that checks setup of health_check. Signed-off-by: Christian Tryti <ctryti@gmail.com>
This commit is contained in:
@@ -51,7 +51,7 @@ forward FROM TO... {
|
||||
tls CERT KEY CA
|
||||
tls_servername NAME
|
||||
policy random|round_robin|sequential
|
||||
health_check DURATION
|
||||
health_check DURATION [no_rec]
|
||||
max_concurrent MAX
|
||||
}
|
||||
~~~
|
||||
@@ -85,7 +85,10 @@ forward FROM TO... {
|
||||
* `random` is a policy that implements random upstream selection.
|
||||
* `round_robin` is a policy that selects hosts based on round robin ordering.
|
||||
* `sequential` is a policy that selects hosts based on sequential ordering.
|
||||
* `health_check`, use a different **DURATION** for health checking, the default duration is 0.5s.
|
||||
* `health_check` configure the behaviour of health checking of the upstream servers
|
||||
* `<duration>` - use a different duration for health checking, the default duration is 0.5s.
|
||||
* `no_rec` - optional argument that sets the RecursionDesired-flag of the dns-query used in health checking to `false`.
|
||||
The flag is default `true`.
|
||||
* `max_concurrent` **MAX** will limit the number of concurrent queries to **MAX**. Any new query that would
|
||||
raise the number of concurrent queries above the **MAX** will result in a SERVFAIL response. This
|
||||
response does not count as a health failure. When choosing a value for **MAX**, pick a number
|
||||
|
||||
Reference in New Issue
Block a user