pub struct RequestDeduplicationClient<C> { /* private fields */ }Expand description
Wraps an inner Client and deduplicates running requests.
The endpoint must be idempotent. In particular, the following things must be guaranteed:
- The endpoint must return the same response on the same request
- The deduplication may fail due to TOCTOU, and sending the same request twice must not change the servers behavioru
Implementations§
Source§impl<C> RequestDeduplicationClient<C>
impl<C> RequestDeduplicationClient<C>
Trait Implementations§
Source§impl<C: Client> Client for RequestDeduplicationClient<C>
impl<C: Client> Client for RequestDeduplicationClient<C>
Source§impl<C: Clone> Clone for RequestDeduplicationClient<C>
impl<C: Clone> Clone for RequestDeduplicationClient<C>
Source§fn clone(&self) -> RequestDeduplicationClient<C>
fn clone(&self) -> RequestDeduplicationClient<C>
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<C: Debug> Debug for RequestDeduplicationClient<C>
impl<C: Debug> Debug for RequestDeduplicationClient<C>
Source§impl<C: Default> Default for RequestDeduplicationClient<C>
impl<C: Default> Default for RequestDeduplicationClient<C>
Source§fn default() -> RequestDeduplicationClient<C>
fn default() -> RequestDeduplicationClient<C>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<C> Freeze for RequestDeduplicationClient<C>where
C: Freeze,
impl<C> RefUnwindSafe for RequestDeduplicationClient<C>where
C: RefUnwindSafe,
impl<C> Send for RequestDeduplicationClient<C>where
C: Send,
impl<C> Sync for RequestDeduplicationClient<C>where
C: Sync,
impl<C> Unpin for RequestDeduplicationClient<C>where
C: Unpin,
impl<C> UnsafeUnpin for RequestDeduplicationClient<C>where
C: UnsafeUnpin,
impl<C> UnwindSafe for RequestDeduplicationClient<C>where
C: UnwindSafe,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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