Skip to main content

Module telemetry

Module telemetry 

Source
Expand description

Metrics for ash-lock.

MOCK: the spec calls for exporting these counters through an ash-telemetry crate, which does not yet exist. This module provides the same AtomicU64-backed counters with a stable API so that, once ash-telemetry lands, the export sink can be swapped in without touching call sites.

The counter names mirror the spec:

  • ash_lock_acquisitions_total
  • ash_lock_contention_events_total
  • ash_lock_renewal_failures_total

Structs§

Snapshot
A point-in-time snapshot of every exported counter. Useful in tests and for the eventual ash-telemetry scrape endpoint.

Statics§

ACQUISITIONS_TOTAL
Number of successful lock acquisitions.
CONTENTION_EVENTS_TOTAL
Number of times an acquire had to block/retry due to contention.
RENEWAL_FAILURES_TOTAL
Number of watchdog renewal failures.

Functions§

snapshot
Read all counters atomically enough for observability purposes.