Enum opentelemetry::metrics::InstrumentKind[][src]

pub enum InstrumentKind {
    ValueRecorder,
    ValueObserver,
    Counter,
    UpDownCounter,
    SumObserver,
    UpDownSumObserver,
}
This is supported on crate feature metrics only.

Kinds of OpenTelemetry metric instruments

NameInstrument kindFunction(argument)Default aggregationNotes
ValueRecorderSynchronousRecord(value)MinMaxSumCountPer-request, any non-additive measurement
ValueObserverAsynchronousObserve(value)MinMaxSumCountPer-interval, any non-additive measurement
CounterSynchronous additive monotonicAdd(increment)SumPer-request, part of a monotonic sum
UpDownCounterSynchronous additiveAdd(increment)SumPer-request, part of a non-monotonic sum
SumObserverAsynchronous additive monotonicObserve(sum)SumPer-interval, reporting a monotonic sum
UpDownSumObserverAsynchronous additiveObserve(sum)SumPer-interval, reporting a non-monotonic sum

Variants

ValueRecorder

A synchronous per-request recorder of non-additive measurements.

ValueObserver

An asynchronous per-interval recorder of non-additive measurements.

Counter

A synchronous per-request part of a monotonic sum.

UpDownCounter

A synchronous per-request part of a non-monotonic sum.

SumObserver

An asynchronous per-interval recorder of a monotonic sum.

UpDownSumObserver

An asynchronous per-interval recorder of a non-monotonic sum.

Implementations

impl InstrumentKind[src]

pub fn synchronous(&self) -> bool[src]

Whether this is a synchronous kind of instrument.

pub fn asynchronous(&self) -> bool[src]

Whether this is a synchronous kind of instrument.

pub fn adding(&self) -> bool[src]

Whether this kind of instrument adds its inputs (as opposed to grouping).

pub fn grouping(&self) -> bool[src]

Whether this kind of instrument groups its inputs (as opposed to adding).

pub fn monotonic(&self) -> bool[src]

Whether this kind of instrument exposes a non-decreasing sum.

pub fn precomputed_sum(&self) -> bool[src]

Whether this kind of instrument receives precomputed sums.

Trait Implementations

impl Clone for InstrumentKind[src]

impl Debug for InstrumentKind[src]

impl Hash for InstrumentKind[src]

impl PartialEq<InstrumentKind> for InstrumentKind[src]

impl StructuralPartialEq for InstrumentKind[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,