Struct jopemachine_raft::ReadState
source · pub struct ReadState {
pub index: u64,
pub request_ctx: Vec<u8>,
}
Expand description
ReadState provides state for read only query. It’s caller’s responsibility to send MsgReadIndex first before getting this state from ready. It’s also caller’s duty to differentiate if this state is what it requests through request_ctx, e.g. given a unique id as request_ctx.
Fields§
§index: u64
The index of the read state.
request_ctx: Vec<u8>
A datagram consisting of context about the request.
Trait Implementations§
source§impl PartialEq for ReadState
impl PartialEq for ReadState
impl Eq for ReadState
impl StructuralPartialEq for ReadState
Auto Trait Implementations§
impl RefUnwindSafe for ReadState
impl Send for ReadState
impl Sync for ReadState
impl Unpin for ReadState
impl UnwindSafe for ReadState
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