pub struct MasterComponentConfig {
pub drain_timeout_ms: u64,
pub reconnect: NetworkRetryPolicy,
pub delegate_retry_max_attempts: Option<u32>,
}Expand description
Configuration for the master/leader-election component.
Controls drain timeout for graceful delegate shutdown and reconnection policy.
§Backward compatibility
The delegate_retry_max_attempts field is retained as a backward-compat alias.
When set (not None), it bridges into reconnect.max_attempts during construction
in MasterComponent::new(). If reconnect is also explicitly configured, the
explicit reconnect value wins.
Fields§
§drain_timeout_ms: u64Timeout in milliseconds for draining a delegate consumer on leadership loss.
reconnect: NetworkRetryPolicyStructured reconnection policy, replacing the flat delegate_retry_max_attempts
field for new configs. Default: unlimited (max_attempts=0).
delegate_retry_max_attempts: Option<u32>Backward-compat alias for reconnect.max_attempts. None means unlimited.
Bridged into reconnect during MasterComponent::new().
Implementations§
Trait Implementations§
Source§impl Clone for MasterComponentConfig
impl Clone for MasterComponentConfig
Source§fn clone(&self) -> MasterComponentConfig
fn clone(&self) -> MasterComponentConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MasterComponentConfig
impl Debug for MasterComponentConfig
Auto Trait Implementations§
impl Freeze for MasterComponentConfig
impl RefUnwindSafe for MasterComponentConfig
impl Send for MasterComponentConfig
impl Sync for MasterComponentConfig
impl Unpin for MasterComponentConfig
impl UnsafeUnpin for MasterComponentConfig
impl UnwindSafe for MasterComponentConfig
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
Mutably borrows from an owned value. Read more