Struct agreed::raft::AppendEntriesRequest [−][src]
pub struct AppendEntriesRequest<D: AppData> { pub term: u64, pub leader_id: u64, pub prev_log_index: u64, pub prev_log_term: u64, pub entries: Vec<Entry<D>>, pub leader_commit: u64, }
Expand description
An RPC sent by a cluster leader to replicate log entries (§5.3), and as a heartbeat (§5.2).
Fields
term: u64
The leader’s current term.
leader_id: u64
The leader’s ID. Useful in redirecting clients.
prev_log_index: u64
The index of the log entry immediately preceding the new entries.
prev_log_term: u64
The term of the prev_log_index
entry.
entries: Vec<Entry<D>>
The new log entries to store.
This may be empty when the leader is sending heartbeats. Entries are batched for efficiency.
leader_commit: u64
The leader’s commit index.
Trait Implementations
impl<D: Debug + AppData> Debug for AppendEntriesRequest<D>
[src]
impl<D: Debug + AppData> Debug for AppendEntriesRequest<D>
[src]impl<'de, D: AppData> Deserialize<'de> for AppendEntriesRequest<D> where
D: AppData,
[src]
impl<'de, D: AppData> Deserialize<'de> for AppendEntriesRequest<D> where
D: AppData,
[src]fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations
impl<D> RefUnwindSafe for AppendEntriesRequest<D> where
D: RefUnwindSafe,
D: RefUnwindSafe,
impl<D> Send for AppendEntriesRequest<D>
impl<D> Sync for AppendEntriesRequest<D>
impl<D> Unpin for AppendEntriesRequest<D> where
D: Unpin,
D: Unpin,
impl<D> UnwindSafe for AppendEntriesRequest<D> where
D: UnwindSafe,
D: UnwindSafe,
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
pub fn vzip(self) -> V
impl<T> WithSubscriber for T
[src]
impl<T> WithSubscriber for T
[src]fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
[src]
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
[src]Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
fn with_current_subscriber(self) -> WithDispatch<Self>
[src]
fn with_current_subscriber(self) -> WithDispatch<Self>
[src]Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,