pub struct UdpHealthConfig {
pub mode: Option<i32>,
pub tcp_port: Option<u32>,
pub rise: Option<u32>,
pub fall: Option<u32>,
pub fail_open: Option<bool>,
pub udp_probe_payload: Option<Vec<u8>>,
pub probe_interval_seconds: Option<u32>,
pub probe_timeout_seconds: Option<u32>,
}Expand description
Optional health-check configuration for a UDP cluster’s backends.
Fields§
§mode: Option<i32>probe mode; defaults to TCP_PROBE when a udp block is present
tcp_port: Option<u32>companion TCP probe port; unset = the backend data port
rise: Option<u32>consecutive successes before a backend is marked up
fall: Option<u32>consecutive failures before a backend is marked down
fail_open: Option<bool>when all backends are down, still forward (don’t drop the flow)
udp_probe_payload: Option<Vec<u8>>payload sent for a UDP_PROBE
probe_interval_seconds: Option<u32>delay between probes, in seconds
probe_timeout_seconds: Option<u32>per-probe response timeout, in seconds
Implementations§
Source§impl UdpHealthConfig
impl UdpHealthConfig
Sourcepub fn mode(&self) -> UdpHealthMode
pub fn mode(&self) -> UdpHealthMode
Returns the enum value of mode, or the default if the field is unset or set to an invalid enum value.
Sourcepub fn set_mode(&mut self, value: UdpHealthMode)
pub fn set_mode(&mut self, value: UdpHealthMode)
Sets mode to the provided enum value.
Sourcepub fn tcp_port(&self) -> u32
pub fn tcp_port(&self) -> u32
Returns the value of tcp_port, or the default value if tcp_port is unset.
Sourcepub fn fail_open(&self) -> bool
pub fn fail_open(&self) -> bool
Returns the value of fail_open, or the default value if fail_open is unset.
Sourcepub fn udp_probe_payload(&self) -> &[u8] ⓘ
pub fn udp_probe_payload(&self) -> &[u8] ⓘ
Returns the value of udp_probe_payload, or the default value if udp_probe_payload is unset.
Sourcepub fn probe_interval_seconds(&self) -> u32
pub fn probe_interval_seconds(&self) -> u32
Returns the value of probe_interval_seconds, or the default value if probe_interval_seconds is unset.
Sourcepub fn probe_timeout_seconds(&self) -> u32
pub fn probe_timeout_seconds(&self) -> u32
Returns the value of probe_timeout_seconds, or the default value if probe_timeout_seconds is unset.
Trait Implementations§
Source§impl Clone for UdpHealthConfig
impl Clone for UdpHealthConfig
Source§fn clone(&self) -> UdpHealthConfig
fn clone(&self) -> UdpHealthConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for UdpHealthConfig
impl Debug for UdpHealthConfig
Source§impl Default for UdpHealthConfig
impl Default for UdpHealthConfig
Source§impl<'de> Deserialize<'de> for UdpHealthConfig
impl<'de> Deserialize<'de> for UdpHealthConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for UdpHealthConfig
Source§impl Hash for UdpHealthConfig
impl Hash for UdpHealthConfig
Source§impl Message for UdpHealthConfig
impl Message for UdpHealthConfig
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.Source§impl Ord for UdpHealthConfig
impl Ord for UdpHealthConfig
Source§fn cmp(&self, other: &UdpHealthConfig) -> Ordering
fn cmp(&self, other: &UdpHealthConfig) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for UdpHealthConfig
impl PartialEq for UdpHealthConfig
Source§fn eq(&self, other: &UdpHealthConfig) -> bool
fn eq(&self, other: &UdpHealthConfig) -> bool
self and other values to be equal, and is used by ==.Source§impl PartialOrd for UdpHealthConfig
impl PartialOrd for UdpHealthConfig
Source§impl Serialize for UdpHealthConfig
impl Serialize for UdpHealthConfig
impl StructuralPartialEq for UdpHealthConfig
Auto Trait Implementations§
impl Freeze for UdpHealthConfig
impl RefUnwindSafe for UdpHealthConfig
impl Send for UdpHealthConfig
impl Sync for UdpHealthConfig
impl Unpin for UdpHealthConfig
impl UnsafeUnpin for UdpHealthConfig
impl UnwindSafe for UdpHealthConfig
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.