[−][src]Struct raft::raw_node::Ready
Ready encapsulates the entries and messages that are ready to read, be saved to stable storage, committed or sent to other peers. All fields in Ready are read-only.
Fields
ss: Option<SoftState>
The current volatile state of a Node. SoftState will be nil if there is no update. It is not required to consume or store SoftState.
hs: Option<HardState>
The current state of a Node to be saved to stable storage BEFORE Messages are sent. HardState will be equal to empty state if there is no update.
read_states: Vec<ReadState>
States can be used for node to serve linearizable read requests locally when its applied index is greater than the index in ReadState. Note that the read_state will be returned when raft receives MsgReadIndex. The returned is only valid for the request that requested to read.
entries: Vec<Entry>
Entries specifies entries to be saved to stable storage BEFORE Messages are sent.
snapshot: Snapshot
Snapshot specifies the snapshot to be saved to stable storage.
committed_entries: Option<Vec<Entry>>
CommittedEntries specifies entries to be committed to a store/state-machine. These have previously been committed to stable store.
messages: Vec<Message>
Messages specifies outbound messages to be sent AFTER Entries are committed to stable storage. If it contains a MsgSnap message, the application MUST report back to raft when the snapshot has been received or has failed by calling ReportSnapshot.
must_sync: bool
MustSync indicates whether the HardState and Entries must be synchronously written to disk or if an asynchronous write is permissible.
Trait Implementations
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,