Add new FallbackExecutor
and update DNS Factory
to use fallback DNS servers when DNS Config
lists multiple servers
#180
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This changeset adds a new
FallbackExecutor
and subsequently updates the DNSFactory
to use fallback DNS servers when DNSConfig
lists multiple servers.Previous versions would only use the first DNS server listed in the DNS
Config
. With these changes applied, it will take up to three DNS servers from this list. This is artificially limited to match default limits in place in most systems (seeMAXNS
config). Internally, it will implement the same strategy that is used in most systems: Always query the first DNS server and if this fails (or times out), use the second DNS server and so on. See alsoman resolv.conf
for details.Most systems (citation needed) use only a single DNS server and would not be affected by this change. A reasonable number of systems (citation needed) use multiple DNS servers as a fallback just in case and have a functioning primary DNS server and would not be affected by this change. A very small number of systems would use multiple DNS servers and have broken connectivity with their primary DNS server, these systems can now resolve DNS queries, albeit with a noticeable delay.
Accordingly, this is a pure future addition that works across all supported platforms and does not affect BC.
Builds on top of #179
Resolves / closes #6
Supersedes / closes #131