cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Camel Quarkus Micrometer metrics cannot be viewed in Dynatrace

AshPerera
Visitor

I have a Camel Quarkus application, and I can successfully view the Camel metrics at http://localhost:8080/metrics.

metrics.png

I’m using the Prometheus extension to expose the /metrics endpoint, and Micrometer to collect metrics.

My goal is to send these Camel Quarkus metrics to Dynatrace.

pom.xml

    <!-- Core Micrometer extension -->
    <dependency>
        <groupId>io.quarkus</groupId>
        <artifactId>quarkus-micrometer</artifactId>
    </dependency>
    
    <!-- Prometheus registry -->
    <dependency>
        <groupId>io.quarkus</groupId>
        <artifactId>quarkus-micrometer-registry-prometheus</artifactId>
    </dependency>
    
    <!-- Camel Micrometer for route metrics -->
    <dependency>
        <groupId>org.apache.camel.quarkus</groupId>
        <artifactId>camel-quarkus-micrometer</artifactId>
    </dependency>
    
    <dependency>
      <groupId>io.quarkiverse.micrometer.registry</groupId>
      <artifactId>quarkus-micrometer-registry-otlp</artifactId>
      <version>2.10.0</version>
    </dependency>


The application is containerized using Docker. I have enabled Dynatrace monitoring on the container, and I’m able to see general metrics like Requests, Traces, CPU, and Memory in Dynatrace. To enable this, I have configured three environment variables for the container (in a .env file).

.env file

DT_TENANT=dwqtest
DT_TENANTTOKEN=PF7test
DT_CONNECTION_POINT=https://{environmentid}.live.dynatrace.com:443

 

Below is my application.properties configuration used to export Camel Micrometer metrics to Dynatrace (built in metrics).

Note : These same properties are also defined in the .env file and used when building the Docker container.

application.properties

quarkus.micrometer.export.prometheus.enabled=true
quarkus.micrometer.export.prometheus.path=/metrics

quarkus.micrometer.binder.http-server.enabled=true 
quarkus.camel.metrics.enable-instrumented-thread-pool-factory=true

quarkus.micrometer.enabled=true
quarkus.camel.metrics.enable=true

# OTLP exporter
quarkus.micrometer.export.otlp.enabled=true
quarkus.micrometer.export.otlp.url=https://{environmentid}.live.dynatrace.com/api/v2/otlp
quarkus.micrometer.export.otlp.headers=Authorization=Api-Token dttest.test
quarkus.micrometer.export.otlp.resource-attributes=service.name=my-camel-app
quarkus.micrometer.export.otlp.step=10s

 

Despite this, I do not see any of the Camel-specific metrics in Dynatrace in the Metrics or Data Explorer section.

Am I missing any required configuration ?

 

4 REPLIES 4

Julius_Loman
DynaMight Legend
DynaMight Legend

Do you see any metrics sent using OTLP from your container? Can you validate first if the exporter works and is sending the data you need?

Certified Dynatrace Master | Alanata a.s., Slovakia, Dynatrace Master Partner

Hi Julius, I dont see any metrics sent using OTLP. Didnt see anything in the docker logs. ☹️

I tried the Metrics API to send Metrics to Dyantrace and it worked :

 

curl -L -X POST 'https://{environmentid}.live.dynatrace.com/api/v2/metrics/ingest' \
-H 'Authorization: Api-Token dt0c01.DFSFSDF324243.TESTSGDGFSDGDSFGDSFGDSGDSFGDSFGD' \
-H 'Content-Type: text/plain' \
--data-raw 'custom.test.metric 123'


Then I was able to see the metrics in the "Metrics" section.

AshPerera_0-1750665435582.png

Goal is to send metrics (Camel metrics) from my Camel Quarkus application. That is not working unfortunately.

@AshPerera what I would do first it to double check if it really sends the metrics using otlp.
I'd setup an otel collector and a simple pipeline just to dump the metrics, see https://opentelemetry.io/docs/languages/js/exporters/#collector-setup 

Certified Dynatrace Master | Alanata a.s., Slovakia, Dynatrace Master Partner

Hi @Julius_Loman, thanks for the reply.

I was able to resolve my issue. 

Camel Quarkus Micrometer metrics can now be viewed in Dynatrace. 

I fixed the issue by upgrading Quarkus to the latest version 3.23.4

AshPerera_0-1750996741839.png


Thanks.

Featured Posts