pub struct RequestContext {
pub request_id: String,
pub downstream_headers: HeaderMap,
pub method: Method,
pub path: String,
pub query: Option<String>,
pub body_bytes: Bytes,
pub cache_breakpoints: Vec<CacheBreakpoint>,
pub canonical_model_id: String,
}Expand description
Parsed downstream request data passed into plugins.
Fields§
§request_id: StringStable request identifier used for logs, audit rows, and upstream traceability.
downstream_headers: HeaderMapDownstream request headers after hop-by-hop stripping.
method: MethodDownstream HTTP method.
path: StringDownstream request path, such as /v1/messages.
query: Option<String>Raw downstream query string without the leading ?.
body_bytes: BytesBuffered request body bytes, required by SigV4 and other signing schemes.
cache_breakpoints: Vec<CacheBreakpoint>Cache breakpoints extracted from the request for prompt cache optimization.
canonical_model_id: StringCanonical model identifier resolved from the request.
Trait Implementations§
Source§impl Clone for RequestContext
impl Clone for RequestContext
Source§fn clone(&self) -> RequestContext
fn clone(&self) -> RequestContext
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 moreAuto Trait Implementations§
impl !Freeze for RequestContext
impl RefUnwindSafe for RequestContext
impl Send for RequestContext
impl Sync for RequestContext
impl Unpin for RequestContext
impl UnsafeUnpin for RequestContext
impl UnwindSafe for RequestContext
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