client_java
GitHub Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

OTel Support

The prometheus-metrics-otel-support module bundles the OpenTelemetry SDK and the Prometheus exporter into a single POM dependency.

Use this module when you want to combine OpenTelemetry instrumentations (e.g. JVM runtime metrics) with the Prometheus Java client on one /metrics endpoint.

Dependencies

implementation 'io.prometheus:prometheus-metrics-otel-support:1.5.0'
<dependency>
    <groupId>io.prometheus</groupId>
    <artifactId>prometheus-metrics-otel-support</artifactId>
    <version>1.5.0</version>
    <type>pom</type>
</dependency>

This single dependency replaces:

  • io.opentelemetry:opentelemetry-sdk
  • io.opentelemetry:opentelemetry-exporter-prometheus

Use Cases

See JVM Runtime Metrics for a concrete example of combining OTel JVM metrics with the Prometheus Java client.