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 fb7c0c0  Observability example project improvements
fb7c0c0 is described below

commit fb7c0c0432b867921c1ff1d2855557c319935d2b
Author: James Netherton <[email protected]>
AuthorDate: Tue Jun 4 07:40:05 2024 +0100

    Observability example project improvements
    
    * Fix typos in README
    * Upgrade and simplify the container setup
    * Add trace-processors option to application.properties
---
 observability/README.adoc                          |  4 +--
 observability/docker-compose.yml                   | 19 +++-------
 observability/otel-collector-config.yaml           | 42 ----------------------
 .../src/main/resources/application.properties      |  4 +++
 4 files changed, 10 insertions(+), 59 deletions(-)

diff --git a/observability/README.adoc b/observability/README.adoc
index 831b2ae..c536c8b 100644
--- a/observability/README.adoc
+++ b/observability/README.adoc
@@ -44,7 +44,7 @@ First using Camel micrometer component (see 
link:src/main/java/org/acme/observab
 
 Which will count each call to the `platform-http:/greeting-provider` endpoint.
 
-The second approach is to benefit from CDI dependnecy injection of the 
`MeterRegistry`:
+The second approach is to benefit from CDI dependency injection of the 
`MeterRegistry`:
 
 [source, java]
 ----
@@ -162,7 +162,7 @@ Then configure the OpenTelemetry exporter in 
`application.properties`:
 quarkus.otel.exporter.otlp.traces.endpoint = 
http://${TELEMETRY_COLLECTOR_COLLECTOR_SERVICE_HOST:localhost}:4317
 ----
 
-NOTE: For information about other OpenTelemetry exporters, refer to the Camel 
Quarkus Opentelemetry 
https://camel.apache.org/camel-quarkus/next/reference/extensions/opentelemetry.html#extensions-opentelemetry-usage-exporters[extension
 documentation].
+NOTE: For information about other OpenTelemetry exporters, refer to the Camel 
Quarkus OpenTelemetry 
https://camel.apache.org/camel-quarkus/next/reference/extensions/opentelemetry.html#extensions-opentelemetry-usage-exporters[extension
 documentation].
 
 To view tracing events, start a tracing server. A simple way of doing this is 
with Docker Compose:
 
diff --git a/observability/docker-compose.yml b/observability/docker-compose.yml
index 0dd55fe..38179d7 100644
--- a/observability/docker-compose.yml
+++ b/observability/docker-compose.yml
@@ -20,20 +20,9 @@ services:
 
   # Jaeger
   jaeger-all-in-one:
-    image: jaegertracing/all-in-one:1.33
+    image: jaegertracing/all-in-one:1.57
     ports:
       - "16686:16686"
-      - "14268:14268"
-      - "14250:14250"
-
-  # Collector
-  otel-collector:
-    image: otel/opentelemetry-collector:0.50.0
-    command: [ "--config=/etc/otel-collector-config.yaml" ]
-    volumes:
-      - ./otel-collector-config.yaml:/etc/otel-collector-config.yaml
-    ports:
-      - "13133:13133" # Health_check extension
-      - "4317:4317"   # OTLP gRPC receiver
-    depends_on:
-      - jaeger-all-in-one
+      - "4317:4317"
+    environment:
+      - COLLECTOR_OTLP_ENABLED=true
\ No newline at end of file
diff --git a/observability/otel-collector-config.yaml 
b/observability/otel-collector-config.yaml
deleted file mode 100644
index b108831..0000000
--- a/observability/otel-collector-config.yaml
+++ /dev/null
@@ -1,42 +0,0 @@
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements.  See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License.  You may obtain a copy of the License at
-#
-#      http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-receivers:
-  otlp:
-    protocols:
-      grpc:
-        endpoint: otel-collector:4317
-
-exporters:
-  jaeger:
-    endpoint: jaeger-all-in-one:14250
-    tls:
-      insecure: true
-
-processors:
-  batch:
-
-extensions:
-  health_check:
-
-service:
-  extensions: [health_check]
-  pipelines:
-    traces:
-      receivers: [otlp]
-      processors: [batch]
-      exporters: [jaeger]
\ No newline at end of file
diff --git a/observability/src/main/resources/application.properties 
b/observability/src/main/resources/application.properties
index 2ce095e..6b619b2 100644
--- a/observability/src/main/resources/application.properties
+++ b/observability/src/main/resources/application.properties
@@ -24,8 +24,12 @@ quarkus.management.enabled = true
 # Identifier for the origin of spans created by the application
 quarkus.application.name = camel-quarkus-observability
 
+# Enables optional tracing of each Camel processor
+# quarkus.camel.opentelemetry.trace-processors=true
+
 # For OTLP
 quarkus.otel.exporter.otlp.traces.endpoint = 
http://${TELEMETRY_COLLECTOR_COLLECTOR_SERVICE_HOST:localhost}:4317
+quarkus.otel.exporter.otlp.traces.timeout = 30s
 
 #
 # Camel

Reply via email to