pub struct OverloadConfig {
pub advertise: bool,
pub feedback: OverloadFeedback,
pub validity: Duration,
pub rate_tolerance_intervals: u32,
pub rate_priority_tolerance_intervals: u32,
pub peer_limit: usize,
pub categorize: fn(&Request) -> RequestCategory,
}Expand description
Endpoint overload-control policy.
Fields§
§advertise: boolAdvertise RFC 7339/7415 client support on every outgoing topmost Via.
Off by default because overload control is an extension negotiated hop by hop. Enabling it
retains the complete loss,rate offer; it does not select a compatibility subset per peer.
feedback: OverloadFeedbackWhat to report upstream when the application queue is full.
validity: DurationHow long that report remains valid.
rate_tolerance_intervals: u32RFC 7415’s TAU1 for ordinary requests, in target inter-request intervals.
rate_priority_tolerance_intervals: u32RFC 7415’s larger TAU2 for protected requests, in target intervals.
peer_limit: usizeMost downstream peers whose feedback sequence and algorithm state are retained.
categorize: fn(&Request) -> RequestCategoryAssign a request to one of RFC 7339 §7.2’s two categories.
Trait Implementations§
Source§impl Clone for OverloadConfig
impl Clone for OverloadConfig
Source§fn clone(&self) -> OverloadConfig
fn clone(&self) -> OverloadConfig
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 moreSource§impl Debug for OverloadConfig
impl Debug for OverloadConfig
Auto Trait Implementations§
impl Freeze for OverloadConfig
impl RefUnwindSafe for OverloadConfig
impl Send for OverloadConfig
impl Sync for OverloadConfig
impl Unpin for OverloadConfig
impl UnsafeUnpin for OverloadConfig
impl UnwindSafe for OverloadConfig
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> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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