#[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 copy 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
§type Storer = StoreReplace<LoadedRequestBody>
type Storer = StoreReplace<LoadedRequestBody>
Specify how an item is stored in the config bag, e.g.
StoreReplace
and StoreAppend
Auto 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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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>
Creates a shared type from an unshared type.