You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by pc...@apache.org on 2025/03/03 13:50:59 UTC

(camel) branch main updated (64ba64bde89 -> dfcaf8f573d)

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

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


    from 64ba64bde89 chore(docs): remove temporary warning
     new 792cfb8fb70 feat(dsl/jbang): Run --observe to replace --metrics and --health
     new dfcaf8f573d chore(doc): observability services default notice

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../modules/ROOT/pages/camel-4x-upgrade-guide-4_11.adoc     |  4 ++++
 .../java/org/apache/camel/dsl/jbang/core/commands/Run.java  | 13 +++++++++++--
 .../src/main/java/org/apache/camel/main/KameletMain.java    |  2 ++
 3 files changed, 17 insertions(+), 2 deletions(-)


(camel) 02/02: chore(doc): observability services default notice

Posted by pc...@apache.org.
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

commit dfcaf8f573dc543b111ad82bad5c2938d05a9767
Author: Pasquale Congiusti <pa...@gmail.com>
AuthorDate: Mon Mar 3 11:20:22 2025 +0100

    chore(doc): observability services default notice
---
 docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_11.adoc | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_11.adoc b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_11.adoc
index b180b7841c8..7d81cf99610 100644
--- a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_11.adoc
+++ b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_11.adoc
@@ -66,3 +66,7 @@ The camel-kafka option `recordMetadata` has changed default from `true` to `fals
 
 The option `lazy-bean` has changed to be default `true` when exporting to make the export
 work in more situations out of the box.
+
+From this version onward the `export` command add the `camel-observability-services` dependency (which includes telemetry, metrics, health and JMX management services out of the box).
+
+The `--health` and `--metrics` flags of `run` command have been deprecated in favor of the newly `--observe` flag which add the `camel-observability-services` dependency (hence including telemetry, metrics, health and JMX management out of the box). For the run command, this has to be explicitly enabled (ie, `camel run  ... --observe`).


(camel) 01/02: feat(dsl/jbang): Run --observe to replace --metrics and --health

Posted by pc...@apache.org.
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

commit 792cfb8fb701aafe9f3b3fbbfee7320a0a615881
Author: Pasquale Congiusti <pa...@gmail.com>
AuthorDate: Mon Mar 3 11:11:10 2025 +0100

    feat(dsl/jbang): Run --observe to replace --metrics and --health
---
 .../java/org/apache/camel/dsl/jbang/core/commands/Run.java  | 13 +++++++++++--
 .../src/main/java/org/apache/camel/main/KameletMain.java    |  2 ++
 2 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/Run.java b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/Run.java
index bc6fefce3a2..2f0205b3f64 100644
--- a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/Run.java
+++ b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/Run.java
@@ -287,13 +287,18 @@ public class Run extends CamelCommand {
     @Option(names = { "--console" }, description = "Developer console at /q/dev on local HTTP server (port 8080 by default)")
     boolean console;
 
-    @Option(names = { "--health" }, description = "Health check at /q/health on local HTTP server (port 8080 by default)")
+    @Option(names = { "--health" },
+            description = "Deprecated: use --observe instead. Health check at /q/health on local HTTP server (port 8080 by default)")
     boolean health;
 
     @Option(names = { "--metrics" },
-            description = "Metrics (Micrometer and Prometheus) at /q/metrics on local HTTP server (port 8080 by default)")
+            description = "Deprecated: use --observe instead. Metrics (Micrometer and Prometheus) at /q/metrics on local HTTP server (port 8080 by default)")
     boolean metrics;
 
+    @Option(names = { "--observe" },
+            description = "Enable observability services")
+    boolean observe;
+
     @Option(names = { "--modeline" }, defaultValue = "true",
             description = "Deprecated, to be removed: Enables Camel-K style modeline")
     boolean modeline = true;
@@ -606,6 +611,10 @@ public class Run extends CamelCommand {
         writeSetting(main, profileProperties, "camel.jbang.quarkusGroupId", quarkusGroupId);
         writeSetting(main, profileProperties, "camel.jbang.quarkusArtifactId", quarkusArtifactId);
 
+        if (observe) {
+            main.addInitialProperty("camel.jbang.dependencies", "camel:observability-services");
+        }
+
         // command line arguments
         if (property != null) {
             for (String p : property) {
diff --git a/dsl/camel-kamelet-main/src/main/java/org/apache/camel/main/KameletMain.java b/dsl/camel-kamelet-main/src/main/java/org/apache/camel/main/KameletMain.java
index c975b3d2c90..2a443b91d34 100644
--- a/dsl/camel-kamelet-main/src/main/java/org/apache/camel/main/KameletMain.java
+++ b/dsl/camel-kamelet-main/src/main/java/org/apache/camel/main/KameletMain.java
@@ -538,12 +538,14 @@ public class KameletMain extends MainCommandLineSupport {
             configure().httpServer().withEnabled(true);
             configure().httpServer().withInfoEnabled(true);
         }
+        // Deprecated: to be replaced by observe flag
         boolean health = "true".equals(getInitialProperties().get(getInstanceType() + ".health"));
         if (health) {
             configure().health().withEnabled(true);
             configure().httpServer().withEnabled(true);
             configure().httpServer().withHealthCheckEnabled(true);
         }
+        // Deprecated: to be replaced by observe flag
         boolean metrics = "true".equals(getInitialProperties().get(getInstanceType() + ".metrics"));
         if (metrics) {
             configure().metrics()