Skip to main content

AggregateMetric

Trait AggregateMetric 

Source
pub trait AggregateMetric:
    Debug
    + Send
    + Sync
    + RefUnwindSafe {
    // Required method
    fn add_duration(&self, duration: Duration);
}
Expand description

A metric owned by one aggregate implementation.

Aggregate implementations use this interface for optional internal subphases. The execution engine owns metric registration and aggregation.

Required Methods§

Source

fn add_duration(&self, duration: Duration)

Adds elapsed time to this metric.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§