Module hotshot_types::traits::metrics
source · Expand description
The Metrics
trait is used to collect information from multiple components in the entire system.
This trait can be used to spawn the following traits:
Counter
: an ever-increasing value (example usage: total bytes send/received)Gauge
: a value that store the latest value, and can go up and down (example usage: amount of users logged in)Histogram
: stores multiple float values based for a graph (example usage: CPU %)- text: stores a constant string in the collected metrics
Structs§
- Use this if you’re not planning to use any metrics. All methods are implemented as a no-op
Traits§
- An ever-incrementing counter
- A family of related counters, partitioned by their label values.
- A gauge that stores the latest value.
- A family of related gauges, partitioned by their label values.
- A histogram which will record a series of points.
- A family of related histograms, partitioned by their label values.
- The metrics type.
- A family of related metrics, partitioned by their label values.
- A family of related text metrics, partitioned by their label values.