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

pcongiusti pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new d67e2ce4e64 feat(components): add health to observability services
d67e2ce4e64 is described below

commit d67e2ce4e647babc1296460e3b8725472dd88dd7
Author: Pasquale Congiusti <[email protected]>
AuthorDate: Thu Nov 21 10:38:32 2024 +0100

    feat(components): add health to observability services
    
    Ref CAMEL-21462
---
 components/camel-observability-services/pom.xml                   | 4 ++++
 .../src/main/docs/observability-services.adoc                     | 6 +++++-
 .../src/main/resources/observability-services.properties          | 8 +++++++-
 3 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/components/camel-observability-services/pom.xml 
b/components/camel-observability-services/pom.xml
index 4e497b4b206..21d9fda8c2e 100644
--- a/components/camel-observability-services/pom.xml
+++ b/components/camel-observability-services/pom.xml
@@ -45,6 +45,10 @@
             <groupId>org.apache.camel</groupId>
             <artifactId>camel-opentelemetry</artifactId>
         </dependency>
+        <dependency>
+            <groupId>org.apache.camel</groupId>
+            <artifactId>camel-health</artifactId>
+        </dependency>
     </dependencies>
 
 </project>
diff --git 
a/components/camel-observability-services/src/main/docs/observability-services.adoc
 
b/components/camel-observability-services/src/main/docs/observability-services.adoc
index d64f49916bd..80459a99e6f 100644
--- 
a/components/camel-observability-services/src/main/docs/observability-services.adoc
+++ 
b/components/camel-observability-services/src/main/docs/observability-services.adoc
@@ -27,6 +27,7 @@ WARNING: the customization of the configuration for this 
component is not availa
 
 The presence of this dependency will provide the following components:
 
+* camel-health
 * camel-micrometer-prometheus
 * camel-opentelemetry
 
@@ -37,6 +38,9 @@ The presence of this dependency will expose the following 
endpoints:
 |====
 |Endpoint | Description
 
+| `/observe/health` | startup probe endpoint
+| `/observe/health/live` | liveness probe endpoint
+| `/observe/health/ready` | readiness probe endpoint
 | `/observe/metrics` | metrics exposed as in Micrometer Prometheus Registry
 
 |====
@@ -59,4 +63,4 @@ This service will expose the port `4318` to `localhost` which 
is the default set
 
 In order to collect the metrics exposed by the application, and, depending on 
the runtime of choice, you will need to start your Camel application with a 
Java agent, whose goal is to push those metrics to the OpenTelemetry compatible 
collector server. Follow the instructions provided in 
xref:others:opentelemetry.adoc#OpenTelemetry-JavaAgent[Opentelemetry Java Agent 
configuration]
 
-WARNING: due to https://issues.apache.org/jira/browse/CAMEL-21460[a flaw in 
the alignment of Opentelemetry dependencies in Spring Boot] runtime you may hit 
a runtime error until the Spring Boot BOM dependencies is aligning the 
Opentelemetry dependencies. Be mindful of the required workaround required for 
this to work.
\ No newline at end of file
+WARNING: due to https://issues.apache.org/jira/browse/CAMEL-21460[a flaw in 
the alignment of Opentelemetry dependencies in Spring Boot] runtime you may hit 
a runtime error until the Spring Boot BOM dependencies is aligning the 
Opentelemetry dependencies. Be mindful of the required workaround required for 
this to work until the issue is fixed.
\ No newline at end of file
diff --git 
a/components/camel-observability-services/src/main/resources/observability-services.properties
 
b/components/camel-observability-services/src/main/resources/observability-services.properties
index 91638ebdfe1..80fde15b5da 100644
--- 
a/components/camel-observability-services/src/main/resources/observability-services.properties
+++ 
b/components/camel-observability-services/src/main/resources/observability-services.properties
@@ -14,10 +14,16 @@
 ## See the License for the specific language governing permissions and
 ## limitations under the License.
 ## ---------------------------------------------------------------------------
+
+# Enable server
 camel.server.enabled=true
+# Prometheus metrics
 camel.server.metricsEnabled=true
 camel.metrics.enabled=true
-# Default metrics endpoint
 camel.metrics.path=/observe/metrics
 # Opentelemetry
 camel.opentelemetry.enabled=true
+# Health
+camel.server.healthCheckEnabled=true
+camel.server.healthPath=/observe/health
+camel.health.exposure-level=full

Reply via email to