foyer_common::metrics

Trait RegistryOps

Source
pub trait RegistryOps:
    Send
    + Sync
    + 'static
    + Debug {
    // Required methods
    fn register_counter_vec(
        &self,
        name: &'static str,
        desc: &'static str,
        label_names: &'static [&'static str],
    ) -> impl CounterVecOps;
    fn register_gauge_vec(
        &self,
        name: &'static str,
        desc: &'static str,
        label_names: &'static [&'static str],
    ) -> impl GaugeVecOps;
    fn register_histogram_vec(
        &self,
        name: &'static str,
        desc: &'static str,
        label_names: &'static [&'static str],
    ) -> impl HistogramVecOps;
}
Expand description

Metrics registry.

Required Methods§

Source

fn register_counter_vec( &self, name: &'static str, desc: &'static str, label_names: &'static [&'static str], ) -> impl CounterVecOps

Register a vector of counters to the registry.

Source

fn register_gauge_vec( &self, name: &'static str, desc: &'static str, label_names: &'static [&'static str], ) -> impl GaugeVecOps

Register a vector of gauges to the registry.

Source

fn register_histogram_vec( &self, name: &'static str, desc: &'static str, label_names: &'static [&'static str], ) -> impl HistogramVecOps

Register a vector of histograms to the registry.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§