pub enum DownloadDiagnosticsOutcome {
Found,
NotFound,
Timeout,
NetworkError,
ProtocolError,
CacheHit,
LookupError,
Exhausted,
}Expand description
The outcome of a single normal-path chunk fetch attempt.
Each variant maps to a stable lowercase string used as the outcome JSON
field. Variants are intentionally exhaustive over the record categories
listed in the design doc.
Variants§
Found
A chunk was successfully fetched from a peer.
NotFound
A queried peer responded NotFound.
Timeout
A peer attempt timed out waiting for a response.
NetworkError
A peer attempt failed at the transport / dial / send layer.
ProtocolError
A peer responded with a structured protocol-level error (e.g. a
corrupted-chunk ChunkGetResponse::Error or a content/address
mismatch).
CacheHit
The chunk was served from the in-memory cache; no peer was contacted.
LookupError
The DHT closest-peer lookup itself failed before any peer was queried.
Exhausted
A sweep queried every selected peer without success.
Implementations§
Trait Implementations§
Source§impl Clone for DownloadDiagnosticsOutcome
impl Clone for DownloadDiagnosticsOutcome
Source§fn clone(&self) -> DownloadDiagnosticsOutcome
fn clone(&self) -> DownloadDiagnosticsOutcome
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 moreimpl Copy for DownloadDiagnosticsOutcome
Source§impl Debug for DownloadDiagnosticsOutcome
impl Debug for DownloadDiagnosticsOutcome
Source§impl Display for DownloadDiagnosticsOutcome
impl Display for DownloadDiagnosticsOutcome
impl Eq for DownloadDiagnosticsOutcome
impl StructuralPartialEq for DownloadDiagnosticsOutcome
Auto Trait Implementations§
impl Freeze for DownloadDiagnosticsOutcome
impl RefUnwindSafe for DownloadDiagnosticsOutcome
impl Send for DownloadDiagnosticsOutcome
impl Sync for DownloadDiagnosticsOutcome
impl Unpin for DownloadDiagnosticsOutcome
impl UnsafeUnpin for DownloadDiagnosticsOutcome
impl UnwindSafe for DownloadDiagnosticsOutcome
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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