Skip to main content

Module metrics

Module metrics 

Source
Expand description

An HTTP endpoint for metrics collection.

ModulesΒ§

catalog
Descriptions of the metrics zebrad itself records.
node_context πŸ”’
The node’s position on the chain, which telemetry backends attach to the signals they send.
process_memory πŸ”’
Records this process’s memory use, so operators can see a node approaching its memory limit before the kernel stops it.
sentry_policy πŸ”’
Shapes every metric for Sentry, which stores each value it receives.

StructsΒ§

Config
Metrics configuration section.
MetricsEndpoint
Abscissa component which runs a metrics endpoint.

ConstantsΒ§

BLOCK_LATENCY_BUCKETS πŸ”’
Bucket upper bounds for block verification, block template, and announcement latency.
DOWNLOAD_BUCKETS πŸ”’
Bucket upper bounds for downloads from peers.
HISTOGRAM_BUCKETS
The histograms that Prometheus exports as histograms with these bucket upper bounds, in seconds. Every other histogram is exported as a summary with quantiles.
PROCESS_METRICS_INTERVAL πŸ”’
How often the process metrics are sampled.
SUB_MILLISECOND_BUCKETS πŸ”’
Bucket upper bounds for work that usually takes well under a millisecond.
_DERIVE_Component_A_FOR_MetricsEndpoint πŸ”’

FunctionsΒ§

describe_all
Describes every metric Zebra records to the current recorder.
describe_and_record_build_info πŸ”’
Describes every metric, registers the failure counters at zero, and records the build info once, through the recorder that was just installed, whichever backends it sends to.
describe_process_metrics πŸ”’
Describes the process metrics recorded by spawn_process_metrics.
install πŸ”’
Installs recorder as the global metrics recorder, then describes every metric and records the build info through it.
install_with_prometheus πŸ”’
Installs the Prometheus recorder from builder, with other beside it if it is provided, as the global recorder, then describes every metric and records the build info through it.
prometheus_builder πŸ”’
Returns the Prometheus exporter’s configuration, before its endpoint is added.
record_process_memory
Records this process’s memory use every SAMPLE_INTERVAL, until the task is aborted.
record_process_metrics πŸ”’
Records one sample of the process metrics.
spawn_process_metrics πŸ”’
Records the process metrics through the global recorder, which must already be installed.
with_prometheus πŸ”’
Returns the recorder that receives every metric: prometheus, and other beside it if it is provided.