pub enum RateLimitUnavailable {
FailOpen,
FailClosed,
}Expand description
Behaviour when the rate-limit store is unavailable (RFC-008 §4).
Variants§
FailOpen
Allow the operation to proceed when the rate-limit store is unavailable. Appropriate when rate limiting is defence-in-depth and availability is preferred over strict enforcement.
FailClosed
Deny the operation when the rate-limit store is unavailable. Use when rate limiting is a hard security requirement and the host prefers a temporary outage over a weakened rate-limit guarantee.
Trait Implementations§
Source§fn clone(&self) -> RateLimitUnavailable
fn clone(&self) -> RateLimitUnavailable
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§fn default() -> RateLimitUnavailable
fn default() -> RateLimitUnavailable
Returns the “default value” for a type. Read more
Source§fn eq(&self, other: &RateLimitUnavailable) -> bool
fn eq(&self, other: &RateLimitUnavailable) -> bool
Tests for
self and other values to be equal, and is used by ==.Auto Trait Implementations§
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