#[non_exhaustive]pub struct ClusterClientSettings {
pub initial_contacts: Vec<String>,
pub establishing_get_contacts_interval: Duration,
pub reconnect_timeout: Duration,
pub max_attempts: u32,
}Expand description
Settings for a ClusterClient.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.initial_contacts: Vec<String>Initial bootstrap addresses to try in order. The first one that responds wins.
establishing_get_contacts_interval: DurationTime to wait for an initial contact before trying the next.
reconnect_timeout: DurationBackoff between full re-attempts after exhausting all initial contacts.
max_attempts: u32Total attempts before giving up.
Implementations§
Source§impl ClusterClientSettings
impl ClusterClientSettings
pub fn with_initial_contacts<I, S>(self, contacts: I) -> Self
pub fn with_max_attempts(self, n: u32) -> Self
Trait Implementations§
Source§impl Clone for ClusterClientSettings
impl Clone for ClusterClientSettings
Source§fn clone(&self) -> ClusterClientSettings
fn clone(&self) -> ClusterClientSettings
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 ClusterClientSettings
impl Debug for ClusterClientSettings
Auto Trait Implementations§
impl Freeze for ClusterClientSettings
impl RefUnwindSafe for ClusterClientSettings
impl Send for ClusterClientSettings
impl Sync for ClusterClientSettings
impl Unpin for ClusterClientSettings
impl UnsafeUnpin for ClusterClientSettings
impl UnwindSafe for ClusterClientSettings
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