pub struct RecordedExchange {
pub recv_ts_ns: u128,
pub latency_ns: Option<u64>,
pub protocol: String,
pub request: Value,
pub response: Option<Value>,
}Expand description
One captured request/response pair plus metadata.
Fields§
§recv_ts_ns: u128Wall-clock nanoseconds since UNIX epoch when the request was received. Replay tools use this to compute relative timing if they want to reproduce arrival rates.
latency_ns: Option<u64>Latency of the response in nanoseconds (from request
receive to response send). None if the request didn’t
complete (timeout / cancel / crash).
protocol: StringFree-form protocol tag (e.g. "openai.chat",
"kserve.embedding"). Replay readers can filter on this.
request: ValueWire-format request as JSON.
response: Option<Value>Wire-format response as JSON, or None for errored / open
exchanges captured mid-flight.
Implementations§
Trait Implementations§
Source§impl Clone for RecordedExchange
impl Clone for RecordedExchange
Source§fn clone(&self) -> RecordedExchange
fn clone(&self) -> RecordedExchange
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 Debug for RecordedExchange
impl Debug for RecordedExchange
Source§impl<'de> Deserialize<'de> for RecordedExchange
impl<'de> Deserialize<'de> for RecordedExchange
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for RecordedExchange
impl RefUnwindSafe for RecordedExchange
impl Send for RecordedExchange
impl Sync for RecordedExchange
impl Unpin for RecordedExchange
impl UnsafeUnpin for RecordedExchange
impl UnwindSafe for RecordedExchange
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> 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