Module mz_storage::statistics
source ยท Expand description
Helpers for managing storage statistics.
This module collects statistics related to sources and sinks. Statistics, as exposed
to their respective system tables have strong semantics, defined within the
mz_storage_types::statistics
module. This module collects and aggregates metrics
across workers according to those semantics.
Note that it simultaneously collect prometheus metrics for the given statistics. Those metrics do not have the same strong semantics, which is by design to ensure we are able to categorically debug sources and sinks during complex failures (or bugs with statistics collection itself). Prometheus metrics are
- Never dropped or reset until a source/sink is dropped.
- Entirely independent across workers.
Structsยง
- A structure that keeps track of local statistics, as well as aggregating statistics into a single worker (currently worker 0).
- Prometheus metrics for user-facing sink metrics.
- Statistics maintained for sinks. Gauges can be uninitialized.
- Meta data needed to maintain source statistics.
- Prometheus metrics for user-facing source metrics.
- Statistics maintained for sources. Gauges can be uninitialized.
- Stats
Inner ๐ - A helper struct designed to make it easy for operators to update user-facing metrics. This struct also ensures that each stack is also incremented in prometheus.
Type Aliasesยง
- Statistics maintained for sinks.
- Statistics maintained for sources.