pub struct FetchPayload {
pub sources: Vec<PeerId>,
pub retry_verification: Option<VerificationEntry>,
}Expand description
The mutable half of a queued fetch, held outside the priority heap.
Neither field participates in FetchOrder’s ordering, and both are read
only once the key is dequeued. Holding them in a key-indexed map is what
lets a further source be merged into an already-queued key in O(1) instead
of costing a full rebuild of the fetch heap.
Fields§
§sources: Vec<PeerId>Verified source peers that responded Present.
retry_verification: Option<VerificationEntry>Pending-verification entry to restore if every fetch source is exhausted before the chunk is recovered.
Trait Implementations§
Source§impl Clone for FetchPayload
impl Clone for FetchPayload
Source§fn clone(&self) -> FetchPayload
fn clone(&self) -> FetchPayload
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for FetchPayload
impl RefUnwindSafe for FetchPayload
impl Send for FetchPayload
impl Sync for FetchPayload
impl Unpin for FetchPayload
impl UnsafeUnpin for FetchPayload
impl UnwindSafe for FetchPayload
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more