Skip to main content

Module telemetry

Module telemetry 

Source
Expand description

Process-wide logging setup shared by every binary.

Modules§

pools
Database pool series: the connection gauges and the acquire-failure counter.
recorder
Prometheus recorder, series names and the /metrics listener shared by the binaries.

Functions§

init_logging
Initialises logging on stderr; stdout is reserved for the binaries’ protocols. Colour codes go only to a terminal, so collected pod logs stay plain text.
init_logging_to
Initialises logging to writer, the filter coming from flag, RUST_LOG or default.
init_with_writer
Installs the global subscriber, writing to writer with colour codes only when ansi, and bridges log records into it.
resolve_filter
Picks the filter: an explicit flag wins, then a valid RUST_LOG, then the default.