Struct ConcurrencyLimitLayer

struct ConcurrencyLimitLayer { ... }

Enforces a limit on the concurrent number of requests the underlying service can handle.

Implementations

impl ConcurrencyLimitLayer

const fn new(max: usize) -> Self

Create a new concurrency limit layer.

impl Clone for ConcurrencyLimitLayer

fn clone(self: &Self) -> ConcurrencyLimitLayer

impl Debug for ConcurrencyLimitLayer

fn fmt(self: &Self, f: &mut Formatter<'_>) -> Result

impl Freeze for ConcurrencyLimitLayer

impl RefUnwindSafe for ConcurrencyLimitLayer

impl Send for ConcurrencyLimitLayer

impl Sync for ConcurrencyLimitLayer

impl Unpin for ConcurrencyLimitLayer

impl UnsafeUnpin for ConcurrencyLimitLayer

impl UnwindSafe for ConcurrencyLimitLayer

impl<S> Layer for ConcurrencyLimitLayer

fn layer(self: &Self, service: S) -> <Self as >::Service

impl<T> Any for ConcurrencyLimitLayer

fn type_id(self: &Self) -> TypeId

impl<T> Borrow for ConcurrencyLimitLayer

fn borrow(self: &Self) -> &T

impl<T> BorrowMut for ConcurrencyLimitLayer

fn borrow_mut(self: &mut Self) -> &mut T

impl<T> CloneToUninit for ConcurrencyLimitLayer

unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)

impl<T> From for ConcurrencyLimitLayer

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> Instrument for ConcurrencyLimitLayer

impl<T> ToOwned for ConcurrencyLimitLayer

fn to_owned(self: &Self) -> T
fn clone_into(self: &Self, target: &mut T)

impl<T> WithSubscriber for ConcurrencyLimitLayer

impl<T, U> Into for ConcurrencyLimitLayer

fn into(self: Self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom for ConcurrencyLimitLayer

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto for ConcurrencyLimitLayer

fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>