pub struct PayloadMetrics {
pub payload_index: usize,
pub metrics: Vec<Metric>,
pub exit_code: i32,
}Expand description
All metrics extracted from a single payload run plus the process exit code.
Each concurrent payload (primary or workload, foreground or
background) produces one PayloadMetrics value. Sidecar stores
these as a Vec<PayloadMetrics> so per-payload provenance is
preserved across composed tests. Payload identity (name and
cgroup placement) is carried by the enclosing sidecar record —
not by PayloadMetrics itself, which holds only the extracted
metrics and exit code.
The payload_index field stamps every per-invocation emission
(one PayloadMetrics value per .run() / .wait() / .kill() /
.try_wait() call) with a monotonically increasing per-process
counter — assigned at emit time inside the guest VM.
Fields§
§payload_index: usizePer-invocation index assigned at emit time. Monotonically increasing within a single guest VM process, starting at 0.
metrics: Vec<Metric>Extracted metrics. Empty when OutputFormat::ExitCode is
used or when JSON parsing found no numeric leaves.
exit_code: i32Process exit code (0 = success). Used by
MetricCheck::ExitCodeEq in the check
evaluation pre-pass.
Implementations§
Trait Implementations§
Source§impl Clone for PayloadMetrics
impl Clone for PayloadMetrics
Source§fn clone(&self) -> PayloadMetrics
fn clone(&self) -> PayloadMetrics
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PayloadMetrics
impl Debug for PayloadMetrics
Source§impl<'de> Deserialize<'de> for PayloadMetrics
impl<'de> Deserialize<'de> for PayloadMetrics
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>,
Auto Trait Implementations§
impl Freeze for PayloadMetrics
impl RefUnwindSafe for PayloadMetrics
impl Send for PayloadMetrics
impl Sync for PayloadMetrics
impl Unpin for PayloadMetrics
impl UnwindSafe for PayloadMetrics
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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>
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>
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