pub struct RateLimitRule {
pub name: String,
pub pattern: String,
pub rpm: u32,
pub burst: u32,
pub key_source: KeySource,
pub delay_mode: DelayMode,
}Expand description
A single rate-limiting rule.
Fields§
§name: StringRule name for identification.
pattern: StringPath glob pattern to match.
rpm: u32Requests per minute (sustained rate).
burst: u32Burst allowance above rpm.
key_source: KeySourceWhat to key on.
delay_mode: DelayModeDelay mode.
Trait Implementations§
Source§impl Clone for RateLimitRule
impl Clone for RateLimitRule
Source§fn clone(&self) -> RateLimitRule
fn clone(&self) -> RateLimitRule
Returns a duplicate of the value. Read more
1.0.0 · 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 RateLimitRule
impl Debug for RateLimitRule
Source§impl<'de> Deserialize<'de> for RateLimitRule
impl<'de> Deserialize<'de> for RateLimitRule
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
Auto Trait Implementations§
impl Freeze for RateLimitRule
impl RefUnwindSafe for RateLimitRule
impl Send for RateLimitRule
impl Sync for RateLimitRule
impl Unpin for RateLimitRule
impl UnsafeUnpin for RateLimitRule
impl UnwindSafe for RateLimitRule
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