[−][src]Struct nakadion::instrumentation::TelemetryDriver
Triggers registered ProcessesTelemetryMessages
to
poll for messages.
Runs its own background thread. The thread stops once this struct is dropped.
A TelemetryDriver
can be 'mounted' into the hierarchy.
If done so, it will still poll its children on its own thread
independently.
Optional Metrics
The driver can be configured to collect metrics on its own activities.
The metrics will be added to all snapshots
under a field named _metrix
which contains the
following fields:
-
collections_per_second
: The number of observation collection runs done per second -
collection_times_us
: A histogram of the time each observation collection took in microseconds. -
observations_processed_per_second
: The number of observations processed per second. -
observations_processed_per_collection
: A histogram of the number of observations processed during each run -
observations_dropped_per_second
: The number of observations dropped per second. See alsomax_observation_age
. -
observations_dropped_per_collection
: A histogram of the number of observations dropped during each run. See alsomax_observation_age
. -
snapshots_per_second
: The number of snapshots taken per second. -
snapshots_times_us
: A histogram of the times it took to take a snapshot in microseconds -
dropped_observations_alarm
: Will betrue
if observations have been dropped. Will by default staytrue
for 60 seconds once triggered. -
inactivity_alarm
: Will betrue
if no observations have been made for a certain amount of time. The default is 60 seconds.
Implementations
impl TelemetryDriver
[src]
pub fn new(
name: Option<String>,
title: Option<String>,
description: Option<String>,
processing_strategy: ProcessingStrategy,
with_driver_metrics: bool
) -> TelemetryDriver
[src]
name: Option<String>,
title: Option<String>,
description: Option<String>,
processing_strategy: ProcessingStrategy,
with_driver_metrics: bool
) -> TelemetryDriver
Creates a new TelemetryDriver
.
max_observation_age
is the maximum age of an Observation
to be taken into account. This is determined by the timestamp
field of an Observation
. Observations
that are too old are simply
dropped. The default is 60 seconds.
pub fn name(&self) -> Option<&str>
[src]
Gets the name of this driver
pub fn change_processing_stragtegy(&self, strategy: ProcessingStrategy)
[src]
Changes the ProcessingStrategy
pub fn pause(&self)
[src]
Pauses processing of observations.
pub fn resume(&self)
[src]
Resumes processing of observations
pub fn snapshot(&self, descriptive: bool) -> Result<Snapshot, GetSnapshotError>
[src]
pub fn snapshot_async(
&self,
descriptive: bool
) -> impl Send + Future<Output = Result<Snapshot, GetSnapshotError>> + 'static
[src]
&self,
descriptive: bool
) -> impl Send + Future<Output = Result<Snapshot, GetSnapshotError>> + 'static
Trait Implementations
impl AggregatesProcessors for TelemetryDriver
[src]
pub fn add_processor<P>(&mut self, processor: P) where
P: ProcessesTelemetryMessages,
[src]
P: ProcessesTelemetryMessages,
pub fn add_snapshooter<S>(&mut self, snapshooter: S) where
S: PutsSnapshot,
[src]
S: PutsSnapshot,
pub fn attached_mount(&mut self, mount: ProcessorMount) -> AttachedMount
[src]
impl Clone for TelemetryDriver
[src]
pub fn clone(&self) -> TelemetryDriver
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Default for TelemetryDriver
[src]
pub fn default() -> TelemetryDriver
[src]
impl Descriptive for TelemetryDriver
[src]
impl ProcessesTelemetryMessages for TelemetryDriver
[src]
pub fn process(
&mut self,
_max: usize,
_strategy: ProcessingStrategy
) -> ProcessingOutcome
[src]
&mut self,
_max: usize,
_strategy: ProcessingStrategy
) -> ProcessingOutcome
Receive and handle pending operations
impl PutsSnapshot for TelemetryDriver
[src]
pub fn put_snapshot(&self, into: &mut Snapshot, descriptive: bool)
[src]
Auto Trait Implementations
impl RefUnwindSafe for TelemetryDriver
impl Send for TelemetryDriver
impl Sync for TelemetryDriver
impl Unpin for TelemetryDriver
impl UnwindSafe for TelemetryDriver
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> SendSyncUnwindSafe for T where
T: Send + Sync + UnwindSafe + ?Sized,
[src]
T: Send + Sync + UnwindSafe + ?Sized,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,