Cargo Features

iroh-metrics = { version = "0.11.0", default-features = false, features = ["metrics"] }
default = metrics

The metrics feature is set by default whenever iroh-metrics is added without default-features = false somewhere in the dependency tree.

metrics default = prometheus-client

Affects core::Counter.counter,, core::Metric.with_metric, metrics::start_metrics_server

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features.

prometheus-client metrics