[][src]Trait opentelemetry::sdk::export::metrics::AggregatorSelector

pub trait AggregatorSelector: Debug {
    pub fn aggregator_for(
        &self,
        descriptor: &Descriptor
    ) -> Option<Arc<dyn Aggregator + Send + Sync>>; }
This is supported on crate feature metrics only.

AggregatorSelector supports selecting the kind of Aggregator to use at runtime for a specific metric instrument.

Required methods

pub fn aggregator_for(
    &self,
    descriptor: &Descriptor
) -> Option<Arc<dyn Aggregator + Send + Sync>>
[src]

This allocates a variable number of aggregators of a kind suitable for the requested export.

When the call returns None, the metric instrument is explicitly disabled.

This must return a consistent type to avoid confusion in later stages of the metrics export process, e.g., when merging or checkpointing aggregators for a specific instrument.

This call should not block.

Loading content...

Implementors

impl AggregatorSelector for Selector[src]

Loading content...