pub struct TablePrepare {
id: Uuid,
request: u64,
}
Expand description
The preparation RPC.
Used to request available bandwidth from a node.
Fields§
§id: Uuid
§request: u64
Trait Implementations§
Source§impl Debug for TablePrepare
impl Debug for TablePrepare
Source§impl<'de> Deserialize<'de> for TablePrepare
impl<'de> Deserialize<'de> for TablePrepare
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
Source§impl From<TablePrepare> for Operations
impl From<TablePrepare> for Operations
Source§fn from(value: TablePrepare) -> Self
fn from(value: TablePrepare) -> Self
Converts to this type from the input type.
Source§impl Rpc for TablePrepare
impl Rpc for TablePrepare
Source§async fn handle(self) -> Result<Self::Response>
async fn handle(self) -> Result<Self::Response>
The preparation RPC’s main body.
Computes available bandwidth and stores the prepared table. Launches the deletion tasks to execute after PREPARE_TIME.
Returns this peer availability zone and proposed bandwidth for this table.
type Request = Operations
type Response = Result<(String, u64), Error>
async fn exec(self, peer: &Peer) -> Result<Self::Response>
Auto Trait Implementations§
impl Freeze for TablePrepare
impl RefUnwindSafe for TablePrepare
impl Send for TablePrepare
impl Sync for TablePrepare
impl Unpin for TablePrepare
impl UnwindSafe for TablePrepare
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