pub enum GreedyConfigError {
PerChannelCapTooLow {
got: u64,
min: u64,
},
TotalCapBelowPerChannel {
total: u64,
per_channel: u64,
},
BudgetFractionOutOfRange {
got: f32,
},
ProximityRttZero,
}Expand description
Typed validation errors. Distinct variants per invariant so the binding layer can route to language-idiomatic error classes without parsing strings.
Variants§
PerChannelCapTooLow
per_channel_cap_bytes is below the floor.
TotalCapBelowPerChannel
total_cap_bytes < per_channel_cap_bytes. A total budget
smaller than a single channel’s cap can’t admit any
channel.
BudgetFractionOutOfRange
bandwidth_budget_fraction outside (0.0, 1.0] or
non-finite (NaN / ±inf).
ProximityRttZero
proximity_max_rtt is zero. A zero RTT bound excludes every
non-local peer and produces a single-node cache — almost
certainly a misconfig.
Trait Implementations§
Source§impl Debug for GreedyConfigError
impl Debug for GreedyConfigError
Source§impl Display for GreedyConfigError
impl Display for GreedyConfigError
Source§impl Error for GreedyConfigError
impl Error for GreedyConfigError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for GreedyConfigError
impl PartialEq for GreedyConfigError
Source§fn eq(&self, other: &GreedyConfigError) -> bool
fn eq(&self, other: &GreedyConfigError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for GreedyConfigError
Auto Trait Implementations§
impl Freeze for GreedyConfigError
impl RefUnwindSafe for GreedyConfigError
impl Send for GreedyConfigError
impl Sync for GreedyConfigError
impl Unpin for GreedyConfigError
impl UnsafeUnpin for GreedyConfigError
impl UnwindSafe for GreedyConfigError
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