pub struct SampledStat { /* private fields */ }Expand description
A SampledStat records a single scalar value measured over one or more
samples. Each sample is recorded over a configurable window. The window can
be defined by number of events or elapsed time (or both, if both are given
the window is complete when either the event count or elapsed time
criterion is met).
All the samples are combined to produce the measurement. When a window is complete the oldest sample is cleared and recycled to begin recording the next sample.
Implementations§
Source§impl SampledStat
impl SampledStat
Trait Implementations§
Source§impl Debug for SampledStat
impl Debug for SampledStat
Source§impl Display for SampledStat
impl Display for SampledStat
Source§impl Measurable for SampledStat
impl Measurable for SampledStat
Auto Trait Implementations§
impl !Freeze for SampledStat
impl !RefUnwindSafe for SampledStat
impl Send for SampledStat
impl Sync for SampledStat
impl Unpin for SampledStat
impl UnsafeUnpin for SampledStat
impl !UnwindSafe for SampledStat
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<M> MetricValueProvider for Mwhere
M: Measurable,
impl<M> MetricValueProvider for Mwhere
M: Measurable,
Source§fn value(&self, config: &MetricConfig, now: i64) -> MetricValue
fn value(&self, config: &MetricConfig, now: i64) -> MetricValue
Returns the current value associated with this metric. Read more
Source§fn type_name(&self) -> Option<&'static str>
fn type_name(&self) -> Option<&'static str>
Returns the provider’s type name, as
KafkaMetric’s Display reports
it, or None for a provider that is a closure. Read more