pub struct ObservationMetricsSink { /* private fields */ }Expand description
Observation drain that records stable monotonic counters.
Implementations§
Source§impl ObservationMetricsSink
impl ObservationMetricsSink
Sourcepub fn new(metrics: Arc<InMemoryMetrics>) -> Self
pub fn new(metrics: Arc<InMemoryMetrics>) -> Self
Creates a drain backed by the provided process-local registry.
Sourcepub fn metrics(&self) -> Arc<InMemoryMetrics> ⓘ
pub fn metrics(&self) -> Arc<InMemoryMetrics> ⓘ
Returns the shared metrics registry.
Trait Implementations§
Source§impl Clone for ObservationMetricsSink
impl Clone for ObservationMetricsSink
Source§fn clone(&self) -> ObservationMetricsSink
fn clone(&self) -> ObservationMetricsSink
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ObservationMetricsSink
impl Debug for ObservationMetricsSink
Source§impl ObservationSink for ObservationMetricsSink
impl ObservationSink for ObservationMetricsSink
Source§fn emit(&self, event: ObservationEvent)
fn emit(&self, event: ObservationEvent)
Emits one event without blocking on external tooling.
Emits an already validated shared event. Read more
Auto Trait Implementations§
impl !RefUnwindSafe for ObservationMetricsSink
impl !UnwindSafe for ObservationMetricsSink
impl Freeze for ObservationMetricsSink
impl Send for ObservationMetricsSink
impl Sync for ObservationMetricsSink
impl Unpin for ObservationMetricsSink
impl UnsafeUnpin for ObservationMetricsSink
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