pub struct KeyMetric {
pub column: String,
pub agg: KeyAgg,
pub family: String,
pub matchers: String,
pub samples: Option<String>,
}Expand description
SRD-113 — one key-metric designation on an execution node:
column: agg(family), where matchers in braces and, for a family
of the session sampler, a sample mode may follow the family
(avg(sysmon_cgroup_cpu_cores{cgroup="node"}, within); SRD-118
§10.1). Designating key metrics both names the
node’s measurables and attaches the node to the table row of its
nearest enclosing anchor (or the spine). family is empty for
the family-less span().
Fields§
§column: String§agg: KeyAgg§family: String§matchers: StringThe matchers written in braces after the family, without the braces: they select among the family’s series. Empty for none.
samples: Option<String>The sample mode written after the family, for a family of the
session sampler: which of its samples count toward the phase
(SRD-118 §5.1). None for the default.
Implementations§
Source§impl KeyMetric
impl KeyMetric
Sourcepub const SAMPLE_MODES: &'static [&'static str]
pub const SAMPLE_MODES: &'static [&'static str]
The sample modes, in the order they are listed to a user. They
are the values of the phase_samples matcher
(nmbrs_metrics::queryapi::phase_samples).
Sourcepub const DEFAULT_SAMPLES: &'static str = "overlapping"
pub const DEFAULT_SAMPLES: &'static str = "overlapping"
The mode a designation of a sampler family has when it names none.
Sourcepub fn is_session_family(family: &str) -> bool
pub fn is_session_family(family: &str) -> bool
True when family is the session sampler’s: recorded by the
session, with no phase label, and read over a phase by its
samples’ times.
Sourcepub fn sample_mode(&self) -> Option<&str>
pub fn sample_mode(&self) -> Option<&str>
The mode this designation’s samples are counted by, when its family is the session sampler’s.