Enum garage_block::manager::BlockRpc
source · pub enum BlockRpc {
Ok,
GetBlock(Hash, Option<OrderTag>),
PutBlock {
hash: Hash,
header: DataBlockHeader,
},
NeedBlockQuery(Hash),
NeedBlockReply(bool),
}
Expand description
RPC messages used to share blocks of data between nodes
Variants§
Ok
GetBlock(Hash, Option<OrderTag>)
Message to ask for a block of data, by hash
PutBlock
Message to send a block of data, either because requested, of for first delivery of new block
NeedBlockQuery(Hash)
Ask other node if they should have this block, but don’t actually have it
NeedBlockReply(bool)
Response : whether the node do require that block
Trait Implementations§
source§impl<'de> Deserialize<'de> for BlockRpc
impl<'de> Deserialize<'de> for BlockRpc
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for BlockRpc
impl RefUnwindSafe for BlockRpc
impl Send for BlockRpc
impl Sync for BlockRpc
impl Unpin for BlockRpc
impl UnwindSafe for BlockRpc
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
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<M> IntoReq<M> for Mwhere
M: Message,
impl<M> IntoReq<M> for Mwhere
M: Message,
source§fn into_req(self) -> Result<Req<M>, Error>
fn into_req(self) -> Result<Req<M>, Error>
Transform the object into a
Req<M>
, serializing the message M
to be sent to remote nodessource§fn into_req_local(self) -> Req<M>
fn into_req_local(self) -> Req<M>
Transform the object into a
Req<M>
, skipping the serialization
of message M, in the case we are not sending this RPC message to
a remote node