Skip to content


Python integration

Bridges → Graphite

It is also possible to expose metrics to systems other than Prometheus. This allows you to take advantage of Prometheus instrumentation even if you are not quite ready to fully transition to Prometheus yet.

Metrics are pushed over TCP in the Graphite plaintext format.

from prometheus_client.bridge.graphite import GraphiteBridge

gb = GraphiteBridge(('', 2003))
# Push once.
# Push every 10 seconds in a daemon thread.

Multiprocess apps

Prometheus client libraries presume a threaded model, where metrics are shared across workers. This doesn’t work so well for languages such as Python where it’s common to have processes rather than threads to handle large workloads.


Regarder OpenTelemetry:

Page last modified: 2023-05-11 17:27:39