pub enum FailureClass {
Transient,
Permanent,
RateLimit,
AuthFailure,
NetworkError,
ServerError,
}Expand description
Classification of a connection failure.
Variants§
Transient
Temporary network issue, DNS timeout, 503.
Permanent
404, 400, invalid auth — won’t succeed on retry.
RateLimit
429 with Retry-After header.
AuthFailure
401/403 — may succeed after token refresh.
NetworkError
Connection refused, DNS failure.
ServerError
Server closed connection unexpectedly.
Trait Implementations§
Source§impl Clone for FailureClass
impl Clone for FailureClass
Source§fn clone(&self) -> FailureClass
fn clone(&self) -> FailureClass
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 FailureClass
Source§impl Debug for FailureClass
impl Debug for FailureClass
Source§impl<'de> Deserialize<'de> for FailureClass
impl<'de> Deserialize<'de> for FailureClass
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
impl Eq for FailureClass
Source§impl PartialEq for FailureClass
impl PartialEq for FailureClass
Source§fn eq(&self, other: &FailureClass) -> bool
fn eq(&self, other: &FailureClass) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for FailureClass
impl Serialize for FailureClass
impl StructuralPartialEq for FailureClass
Auto Trait Implementations§
impl Freeze for FailureClass
impl RefUnwindSafe for FailureClass
impl Send for FailureClass
impl Sync for FailureClass
impl Unpin for FailureClass
impl UnsafeUnpin for FailureClass
impl UnwindSafe for FailureClass
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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§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.