Crate metrics_generic
source ·Expand description
Provides noop implementations of metrics interfaces, to be used by builds which don’t wish to log metrics.
Modules§
- client 🔒
- Provides an tool for metrics client cleanup which may hold global state.
Structs§
- Ensures any cleanup necessary is performed on drop. Can be used to ensure cleanup is done regardless of how the caller exits. Should be idempotent.
- A logging struct meant for use in tracking and periodically logging a single metric. The metric is aggregated over the designated time period. Intended for use with high-frequency metrics.
Constants§
Functions§
- This interface exists to be used and re-implemented by downstream forks. Updates shouldn’t be done without ensuring they won’t cause breakages in dependent codebases.
- Logs a counter with the given descriptor as aux. data. A descriptor is generally an enum value or error code.
- Logs a counter with no aux. data.
- Logs a counter with additional data.
- Logs a high frequency counter with the supplied aux. data and value.
- Logs a histogram metric with the supplied value. Note: step is a value to be added to the distribution.
- Logs a real valued metric (e.g. a data transfer rate, a latency value, etc) with the supplied value.