pub enum RateLimitScope {
Global,
ClientIp,
Principal,
ApiKey,
Custom(AuthorizationName),
}Expand description
Identity dimension used to derive a rate-limit key.
Variants§
Global
One shared limit for the endpoint.
ClientIp
One limit per normalized client network address.
Principal
One limit per authenticated principal.
ApiKey
One limit per authenticated API key.
Custom(AuthorizationName)
An adapter or application supplies a named key resolver.
Trait Implementations§
Source§impl Clone for RateLimitScope
impl Clone for RateLimitScope
Source§fn clone(&self) -> RateLimitScope
fn clone(&self) -> RateLimitScope
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 RateLimitScope
impl Debug for RateLimitScope
Source§impl Default for RateLimitScope
impl Default for RateLimitScope
Source§fn default() -> RateLimitScope
fn default() -> RateLimitScope
Returns the “default value” for a type. Read more
impl Eq for RateLimitScope
Source§impl PartialEq for RateLimitScope
impl PartialEq for RateLimitScope
impl StructuralPartialEq for RateLimitScope
Auto Trait Implementations§
impl Freeze for RateLimitScope
impl RefUnwindSafe for RateLimitScope
impl Send for RateLimitScope
impl Sync for RateLimitScope
impl Unpin for RateLimitScope
impl UnsafeUnpin for RateLimitScope
impl UnwindSafe for RateLimitScope
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