#[non_exhaustive]pub enum LoadedRequestBody {
NotNeeded,
Requested,
Loaded(Bytes),
}Expand description
Informs the orchestrator on whether or not the request body needs to be loaded into memory before transmit.
This enum gets placed into the ConfigBag to change the orchestrator behavior.
Immediately after serialization (before the read_after_serialization interceptor hook),
if it was set to Requested in the config bag, it will be replaced back into the config bag as
Loaded with the request body contents for use in later interceptors.
This all happens before the attempt loop, so the loaded request body will remain available for interceptors that run in any subsequent retry attempts.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
NotNeeded
Don’t attempt to load the request body into memory.
Requested
Attempt to load the request body into memory.
Loaded(Bytes)
The request body is already loaded.
Trait Implementations§
Source§impl Clone for LoadedRequestBody
impl Clone for LoadedRequestBody
Source§fn clone(&self) -> LoadedRequestBody
fn clone(&self) -> LoadedRequestBody
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 LoadedRequestBody
impl Debug for LoadedRequestBody
Source§impl Storable for LoadedRequestBody
impl Storable for LoadedRequestBody
Source§type Storer = StoreReplace<LoadedRequestBody>
type Storer = StoreReplace<LoadedRequestBody>
Specify how an item is stored in the config bag, e.g.
StoreReplace and StoreAppendAuto Trait Implementations§
impl !Freeze for LoadedRequestBody
impl RefUnwindSafe for LoadedRequestBody
impl Send for LoadedRequestBody
impl Sync for LoadedRequestBody
impl Unpin for LoadedRequestBody
impl UnwindSafe for LoadedRequestBody
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
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 moreCreates a shared type from an unshared type.