This is an automated email from the ASF dual-hosted git repository.

jamesnetherton pushed a commit to branch camel-quarkus-main
in repository https://gitbox.apache.org/repos/asf/camel-quarkus-examples.git


The following commit(s) were added to refs/heads/camel-quarkus-main by this 
push:
     new cbc2288  Fix example for ability to use Jaeger exporter only
cbc2288 is described below

commit cbc2288dc546a7ab10af3de4ad110642b687b152
Author: Lukas Lowinger <llowi...@redhat.com>
AuthorDate: Wed Aug 3 09:33:33 2022 +0200

    Fix example for ability to use Jaeger exporter only
---
 observability/README.adoc                            | 20 ++++++++++++++++++++
 observability/docker-compose.yml                     |  5 ++---
 .../src/main/resources/application.properties        |  4 +++-
 3 files changed, 25 insertions(+), 4 deletions(-)

diff --git a/observability/README.adoc b/observability/README.adoc
index fad3fff..5a697a9 100644
--- a/observability/README.adoc
+++ b/observability/README.adoc
@@ -63,6 +63,26 @@ You can also directly leverage MicroProfile Health APIs to 
create checks. Class
 
 The tracing configuration for the application can be found within 
`application.properties`.
 
+The default configuration uses the OTLP exporter, but it can be easily 
switched to the Jaeger exporter by applying this change in 
`application.properties`:
+
+[source,shell]
+----
+- quarkus.opentelemetry.tracer.exporter.otlp.endpoint=http://localhost:4317
++ quarkus.opentelemetry.tracer.exporter.jaeger.endpoint=http://localhost:14250
+----
+
+and this change in `pom.xml`:
+
+[source,xml]
+----
+        <dependency>
+            <groupId>io.quarkus</groupId>
+-           <artifactId>quarkus-opentelemetry-exporter-otlp</artifactId>
++           <artifactId>quarkus-opentelemetry-exporter-jaeger</artifactId>
+        </dependency>
+----
+
+
 To view tracing events, start a tracing server. A simple way of doing this is 
with Docker Compose:
 
 [source,shell]
diff --git a/observability/docker-compose.yml b/observability/docker-compose.yml
index eb60f01..0dd55fe 100644
--- a/observability/docker-compose.yml
+++ b/observability/docker-compose.yml
@@ -23,8 +23,8 @@ services:
     image: jaegertracing/all-in-one:1.33
     ports:
       - "16686:16686"
-      - "14268"
-      - "14250"
+      - "14268:14268"
+      - "14250:14250"
 
   # Collector
   otel-collector:
@@ -35,6 +35,5 @@ services:
     ports:
       - "13133:13133" # Health_check extension
       - "4317:4317"   # OTLP gRPC receiver
-      - "55680:55680" # OTLP gRPC receiver alternative port
     depends_on:
       - jaeger-all-in-one
diff --git a/observability/src/main/resources/application.properties 
b/observability/src/main/resources/application.properties
index 876d847..d604261 100644
--- a/observability/src/main/resources/application.properties
+++ b/observability/src/main/resources/application.properties
@@ -23,8 +23,10 @@ quarkus.banner.enabled = false
 # Identifier for the origin of spans created by the application
 quarkus.application.name=camel-quarkus-observability
 
-# gRPC endpoint for sending spans
+# For OTLP
 quarkus.opentelemetry.tracer.exporter.otlp.endpoint=http://localhost:4317
+# For Jaeger
+# quarkus.opentelemetry.tracer.exporter.jaeger.endpoint=http://localhost:14250
 
 # Allow metrics to be exported as JSON. Not strictly required and is disabled 
by default
 quarkus.micrometer.export.json.enabled = true

Reply via email to