#[non_exhaustive]pub enum FallbackMode {
Never,
Eager,
IfSystemEmpty,
Deferred,
}Expand description
How the resolver uses its fallback nameservers relative to the primary ones.
The primary nameservers come from the system DNS configuration and the
nameservers added on the Builder. The fallback nameservers default to a
set of public resolvers, which Builder::fallback_nameserver_configs can
override. Select the mode with Builder::with_fallback_mode.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Never
Never queries the fallback nameservers.
Eager
Races the fallback nameservers alongside the primary ones from the start.
IfSystemEmpty
Uses the fallback nameservers only when the system configuration is empty.
A system configuration counts as empty when it yields no nameservers,
whether because it could not be read or because it listed none. One that
did yield nameservers is never supplemented: if those fail at query time
the lookup fails rather than escalating. Without
Builder::with_system_defaults there is no configuration at all, which
also counts as empty, so this behaves like Self::Eager then.
Deferred
Keeps the fallback nameservers as a lower-priority tier.
They are queried only once every primary nameserver has failed or timed out. This is the default.
Trait Implementations§
Source§impl Clone for FallbackMode
impl Clone for FallbackMode
Source§fn clone(&self) -> FallbackMode
fn clone(&self) -> FallbackMode
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for FallbackMode
impl Debug for FallbackMode
Source§impl Default for FallbackMode
impl Default for FallbackMode
Source§fn default() -> FallbackMode
fn default() -> FallbackMode
Source§impl PartialEq for FallbackMode
impl PartialEq for FallbackMode
impl Copy for FallbackMode
impl Eq for FallbackMode
impl StructuralPartialEq for FallbackMode
Auto Trait Implementations§
impl Freeze for FallbackMode
impl RefUnwindSafe for FallbackMode
impl Send for FallbackMode
impl Sync for FallbackMode
impl Unpin for FallbackMode
impl UnwindSafe for FallbackMode
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.