pub struct NoOpCoreMeter;Expand description
A CoreMeter implementation that discards all metric recordings.
Trait Implementations§
Source§impl CoreMeter for NoOpCoreMeter
impl CoreMeter for NoOpCoreMeter
Source§fn new_attributes(&self, attribs: NewAttributes) -> MetricAttributes
fn new_attributes(&self, attribs: NewAttributes) -> MetricAttributes
Given some k/v pairs, create a return a new instantiated instance of metric attributes.
Only MetricAttributes created by this meter can be used when calling record on instruments
created by this meter.
Source§fn extend_attributes(
&self,
existing: MetricAttributes,
attribs: NewAttributes,
) -> MetricAttributes
fn extend_attributes( &self, existing: MetricAttributes, attribs: NewAttributes, ) -> MetricAttributes
Extend some existing attributes with new values. Implementations should create new instances
when doing so, rather than mutating whatever is backing the passed in
existing attributes.
Ideally that new instance retains a ref to the extended old attribute, promoting re-use.Source§fn counter(&self, _: MetricParameters) -> Counter
fn counter(&self, _: MetricParameters) -> Counter
Create a new counter instrument.
Source§fn histogram(&self, _: MetricParameters) -> Histogram
fn histogram(&self, _: MetricParameters) -> Histogram
Create a new histogram instrument recording
u64 values.Source§fn histogram_f64(&self, _: MetricParameters) -> HistogramF64
fn histogram_f64(&self, _: MetricParameters) -> HistogramF64
Create a new histogram instrument recording
f64 values.Source§fn histogram_duration(&self, _: MetricParameters) -> HistogramDuration
fn histogram_duration(&self, _: MetricParameters) -> HistogramDuration
Create a histogram which records Durations. Implementations should choose to emit in
either milliseconds or seconds depending on how they have been configured.
MetricParameters::unit should be overwritten by implementations to be
ms or s
accordingly.Source§fn gauge(&self, _: MetricParameters) -> Gauge
fn gauge(&self, _: MetricParameters) -> Gauge
Create a new gauge instrument recording
u64 values.Source§fn gauge_f64(&self, _: MetricParameters) -> GaugeF64
fn gauge_f64(&self, _: MetricParameters) -> GaugeF64
Create a new gauge instrument recording
f64 values.Source§fn counter_with_in_memory(
&self,
params: MetricParameters,
in_memory_counter: HeartbeatMetricType,
) -> Counter
fn counter_with_in_memory( &self, params: MetricParameters, in_memory_counter: HeartbeatMetricType, ) -> Counter
Create a counter with in-memory tracking for worker heartbeating reporting
Source§fn histogram_duration_with_in_memory(
&self,
params: MetricParameters,
in_memory_hist: HeartbeatMetricType,
) -> HistogramDuration
fn histogram_duration_with_in_memory( &self, params: MetricParameters, in_memory_hist: HeartbeatMetricType, ) -> HistogramDuration
Create a histogram duration with in-memory tracking for worker heartbeating reporting
Source§fn gauge_with_in_memory(
&self,
params: MetricParameters,
in_memory_metrics: HeartbeatMetricType,
) -> Gauge
fn gauge_with_in_memory( &self, params: MetricParameters, in_memory_metrics: HeartbeatMetricType, ) -> Gauge
Create a gauge with in-memory tracking for worker heartbeating reporting
Auto Trait Implementations§
impl Freeze for NoOpCoreMeter
impl RefUnwindSafe for NoOpCoreMeter
impl Send for NoOpCoreMeter
impl Sync for NoOpCoreMeter
impl Unpin for NoOpCoreMeter
impl UnsafeUnpin for NoOpCoreMeter
impl UnwindSafe for NoOpCoreMeter
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<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request