#[non_exhaustive]pub enum ErrorClass {
Client,
Server,
}Expand description
Coarse responsibility class for an Error. Two values by design —
“transient” / “permanent” is a retry-policy axis, orthogonal to
responsibility, and surfaced via Error::Provider’s
retry_after field plus the RetryClassifier policy surface.
Maps onto the standard HTTP family split: Client ≈ 4xx-equivalent
(caller / integrator can act to fix), Server ≈ 5xx-equivalent
(vendor or deployment must act).
JSON serialisation produces "client" / "server" to match the
std::fmt::Display form — wire dashboards keying off the lower-
case bucket stay consistent across the OTel / SSE / audit surfaces.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Client
The caller — request shape, credentials, quota, cancellation choice — is the actor that can resolve the failure.
Server
The SDK, vendor, or deployment environment is the actor that can resolve the failure.
Trait Implementations§
Source§impl Clone for ErrorClass
impl Clone for ErrorClass
Source§fn clone(&self) -> ErrorClass
fn clone(&self) -> ErrorClass
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ErrorClass
impl Debug for ErrorClass
Source§impl Display for ErrorClass
impl Display for ErrorClass
Source§impl Hash for ErrorClass
impl Hash for ErrorClass
Source§impl PartialEq for ErrorClass
impl PartialEq for ErrorClass
Source§fn eq(&self, other: &ErrorClass) -> bool
fn eq(&self, other: &ErrorClass) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for ErrorClass
impl Serialize for ErrorClass
impl Copy for ErrorClass
impl Eq for ErrorClass
impl StructuralPartialEq for ErrorClass
Auto Trait Implementations§
impl Freeze for ErrorClass
impl RefUnwindSafe for ErrorClass
impl Send for ErrorClass
impl Sync for ErrorClass
impl Unpin for ErrorClass
impl UnsafeUnpin for ErrorClass
impl UnwindSafe for ErrorClass
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
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§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.