Struct bollard::models::SwarmSpecRaft
source · pub struct SwarmSpecRaft {
pub snapshot_interval: Option<u64>,
pub keep_old_snapshots: Option<u64>,
pub log_entries_for_slow_followers: Option<u64>,
pub election_tick: Option<i64>,
pub heartbeat_tick: Option<i64>,
}
Expand description
Raft configuration.
Fields§
§snapshot_interval: Option<u64>
The number of log entries between snapshots.
keep_old_snapshots: Option<u64>
The number of snapshots to keep beyond the current snapshot.
log_entries_for_slow_followers: Option<u64>
The number of log entries to keep around to sync up slow followers after a snapshot is created.
election_tick: Option<i64>
The number of ticks that a follower will wait for a message from the leader before becoming a candidate and starting an election. ElectionTick
must be greater than HeartbeatTick
. A tick currently defaults to one second, so these translate directly to seconds currently, but this is NOT guaranteed.
heartbeat_tick: Option<i64>
The number of ticks between heartbeats. Every HeartbeatTick ticks, the leader will send a heartbeat to the followers. A tick currently defaults to one second, so these translate directly to seconds currently, but this is NOT guaranteed.
Trait Implementations§
source§impl Clone for SwarmSpecRaft
impl Clone for SwarmSpecRaft
source§fn clone(&self) -> SwarmSpecRaft
fn clone(&self) -> SwarmSpecRaft
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for SwarmSpecRaft
impl Debug for SwarmSpecRaft
source§impl Default for SwarmSpecRaft
impl Default for SwarmSpecRaft
source§fn default() -> SwarmSpecRaft
fn default() -> SwarmSpecRaft
source§impl<'de> Deserialize<'de> for SwarmSpecRaft
impl<'de> Deserialize<'de> for SwarmSpecRaft
source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<SwarmSpecRaft, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<SwarmSpecRaft, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
source§impl PartialEq for SwarmSpecRaft
impl PartialEq for SwarmSpecRaft
source§impl Serialize for SwarmSpecRaft
impl Serialize for SwarmSpecRaft
source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
impl StructuralPartialEq for SwarmSpecRaft
Auto Trait Implementations§
impl Freeze for SwarmSpecRaft
impl RefUnwindSafe for SwarmSpecRaft
impl Send for SwarmSpecRaft
impl Sync for SwarmSpecRaft
impl Unpin for SwarmSpecRaft
impl UnwindSafe for SwarmSpecRaft
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,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)