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

oscerd 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 c18317d965e7 CAMEL-23510: camel-jgroups - align Exchange header 
constant names with Camel naming convention
c18317d965e7 is described below

commit c18317d965e785cc4605564135c89f3f69874109
Author: Andrea Cosentino <[email protected]>
AuthorDate: Thu May 14 11:07:03 2026 +0200

    CAMEL-23510: camel-jgroups - align Exchange header constant names with 
Camel naming convention
    
    Rename the Exchange header string values in JGroupsConstants from raw
    uppercase (JGROUPS_DEST, JGROUPS_SRC, JGROUPS_CHANNEL_ADDRESS,
    JGROUPS_ORIGINAL_MESSAGE) to the Camel naming convention
    (CamelJGroupsDest, CamelJGroupsSrc, CamelJGroupsChannelAddress,
    CamelJGroupsOriginalMessage). The Java field names are unchanged so
    routes referencing the constants symbolically continue to work. Routes
    using the literal string value must be updated.
    
    Adds an entry to the 4.21 upgrade guide and regenerates the affected
    catalog, component metadata, and endpoint DSL.
    
    Closes #23209
---
 .../apache/camel/catalog/components/jgroups.json   |  8 ++++----
 .../apache/camel/component/jgroups/jgroups.json    |  8 ++++----
 .../camel/component/jgroups/JGroupsConstants.java  |  8 ++++----
 .../ROOT/pages/camel-4x-upgrade-guide-4_21.adoc    | 21 +++++++++++++++++++
 .../dsl/JGroupsEndpointBuilderFactory.java         | 24 +++++++++++-----------
 5 files changed, 45 insertions(+), 24 deletions(-)

diff --git 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/jgroups.json
 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/jgroups.json
index 10c8dda1f81a..8b0959730c49 100644
--- 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/jgroups.json
+++ 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/jgroups.json
@@ -32,10 +32,10 @@
     "autowiredEnabled": { "index": 5, "kind": "property", "displayName": 
"Autowired Enabled", "group": "advanced", "label": "advanced", "required": 
false, "type": "boolean", "javaType": "boolean", "deprecated": false, 
"autowired": false, "secret": false, "defaultValue": true, "description": 
"Whether autowiring is enabled. This is used for automatic autowiring options 
(the option must be marked as autowired) by looking up in the registry to find 
if there is a single instance of matching t [...]
   },
   "headers": {
-    "JGROUPS_CHANNEL_ADDRESS": { "index": 0, "kind": "header", "displayName": 
"", "group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Address", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "Address (org.jgroups.Address) of the 
channel associated with the endpoint.", "constantName": 
"org.apache.camel.component.jgroups.JGroupsConstants#HEADER_JGROUPS_CHANNEL_ADDRESS"
 },
-    "JGROUPS_DEST": { "index": 1, "kind": "header", "displayName": "", 
"group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Address", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "Consumer: The org.jgroups.Address 
instance extracted by org.jgroups.Message.getDest() method of the consumed 
message. Producer: The custom destination org.jgroups.Address of the message to 
be sent.", "constantName": "org.apache.camel.comp [...]
-    "JGROUPS_SRC": { "index": 2, "kind": "header", "displayName": "", "group": 
"common", "label": "", "required": false, "javaType": "org.jgroups.Address", 
"deprecated": false, "deprecationNote": "", "autowired": false, "secret": 
false, "description": "Consumer : The org.jgroups.Address instance extracted by 
org.jgroups.Message.getSrc() method of the consumed message. Producer: The 
custom source org.jgroups.Address of the message to be sent.", "constantName": 
"org.apache.camel.component. [...]
-    "JGROUPS_ORIGINAL_MESSAGE": { "index": 3, "kind": "header", "displayName": 
"", "group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Message", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "The original org.jgroups.Message 
instance from which the body of the consumed message has been extracted.", 
"constantName": 
"org.apache.camel.component.jgroups.JGroupsConstants#HEADER_JGROUPS_ORIGINAL_MESSAGE"
 }
+    "CamelJGroupsChannelAddress": { "index": 0, "kind": "header", 
"displayName": "", "group": "common", "label": "", "required": false, 
"javaType": "org.jgroups.Address", "deprecated": false, "deprecationNote": "", 
"autowired": false, "secret": false, "description": "Address 
(org.jgroups.Address) of the channel associated with the endpoint.", 
"constantName": 
"org.apache.camel.component.jgroups.JGroupsConstants#HEADER_JGROUPS_CHANNEL_ADDRESS"
 },
+    "CamelJGroupsDest": { "index": 1, "kind": "header", "displayName": "", 
"group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Address", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "Consumer: The org.jgroups.Address 
instance extracted by org.jgroups.Message.getDest() method of the consumed 
message. Producer: The custom destination org.jgroups.Address of the message to 
be sent.", "constantName": "org.apache.camel. [...]
+    "CamelJGroupsSrc": { "index": 2, "kind": "header", "displayName": "", 
"group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Address", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "Consumer : The org.jgroups.Address 
instance extracted by org.jgroups.Message.getSrc() method of the consumed 
message. Producer: The custom source org.jgroups.Address of the message to be 
sent.", "constantName": "org.apache.camel.compon [...]
+    "CamelJGroupsOriginalMessage": { "index": 3, "kind": "header", 
"displayName": "", "group": "common", "label": "", "required": false, 
"javaType": "org.jgroups.Message", "deprecated": false, "deprecationNote": "", 
"autowired": false, "secret": false, "description": "The original 
org.jgroups.Message instance from which the body of the consumed message has 
been extracted.", "constantName": 
"org.apache.camel.component.jgroups.JGroupsConstants#HEADER_JGROUPS_ORIGINAL_MESSAGE"
 }
   },
   "properties": {
     "clusterName": { "index": 0, "kind": "path", "displayName": "Cluster 
Name", "group": "common", "label": "", "required": true, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", 
"autowired": false, "secret": false, "description": "The name of the JGroups 
cluster the component should connect to." },
diff --git 
a/components/camel-jgroups/src/generated/resources/META-INF/org/apache/camel/component/jgroups/jgroups.json
 
b/components/camel-jgroups/src/generated/resources/META-INF/org/apache/camel/component/jgroups/jgroups.json
index 10c8dda1f81a..8b0959730c49 100644
--- 
a/components/camel-jgroups/src/generated/resources/META-INF/org/apache/camel/component/jgroups/jgroups.json
+++ 
b/components/camel-jgroups/src/generated/resources/META-INF/org/apache/camel/component/jgroups/jgroups.json
@@ -32,10 +32,10 @@
     "autowiredEnabled": { "index": 5, "kind": "property", "displayName": 
"Autowired Enabled", "group": "advanced", "label": "advanced", "required": 
false, "type": "boolean", "javaType": "boolean", "deprecated": false, 
"autowired": false, "secret": false, "defaultValue": true, "description": 
"Whether autowiring is enabled. This is used for automatic autowiring options 
(the option must be marked as autowired) by looking up in the registry to find 
if there is a single instance of matching t [...]
   },
   "headers": {
-    "JGROUPS_CHANNEL_ADDRESS": { "index": 0, "kind": "header", "displayName": 
"", "group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Address", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "Address (org.jgroups.Address) of the 
channel associated with the endpoint.", "constantName": 
"org.apache.camel.component.jgroups.JGroupsConstants#HEADER_JGROUPS_CHANNEL_ADDRESS"
 },
-    "JGROUPS_DEST": { "index": 1, "kind": "header", "displayName": "", 
"group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Address", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "Consumer: The org.jgroups.Address 
instance extracted by org.jgroups.Message.getDest() method of the consumed 
message. Producer: The custom destination org.jgroups.Address of the message to 
be sent.", "constantName": "org.apache.camel.comp [...]
-    "JGROUPS_SRC": { "index": 2, "kind": "header", "displayName": "", "group": 
"common", "label": "", "required": false, "javaType": "org.jgroups.Address", 
"deprecated": false, "deprecationNote": "", "autowired": false, "secret": 
false, "description": "Consumer : The org.jgroups.Address instance extracted by 
org.jgroups.Message.getSrc() method of the consumed message. Producer: The 
custom source org.jgroups.Address of the message to be sent.", "constantName": 
"org.apache.camel.component. [...]
-    "JGROUPS_ORIGINAL_MESSAGE": { "index": 3, "kind": "header", "displayName": 
"", "group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Message", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "The original org.jgroups.Message 
instance from which the body of the consumed message has been extracted.", 
"constantName": 
"org.apache.camel.component.jgroups.JGroupsConstants#HEADER_JGROUPS_ORIGINAL_MESSAGE"
 }
+    "CamelJGroupsChannelAddress": { "index": 0, "kind": "header", 
"displayName": "", "group": "common", "label": "", "required": false, 
"javaType": "org.jgroups.Address", "deprecated": false, "deprecationNote": "", 
"autowired": false, "secret": false, "description": "Address 
(org.jgroups.Address) of the channel associated with the endpoint.", 
"constantName": 
"org.apache.camel.component.jgroups.JGroupsConstants#HEADER_JGROUPS_CHANNEL_ADDRESS"
 },
+    "CamelJGroupsDest": { "index": 1, "kind": "header", "displayName": "", 
"group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Address", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "Consumer: The org.jgroups.Address 
instance extracted by org.jgroups.Message.getDest() method of the consumed 
message. Producer: The custom destination org.jgroups.Address of the message to 
be sent.", "constantName": "org.apache.camel. [...]
+    "CamelJGroupsSrc": { "index": 2, "kind": "header", "displayName": "", 
"group": "common", "label": "", "required": false, "javaType": 
"org.jgroups.Address", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "Consumer : The org.jgroups.Address 
instance extracted by org.jgroups.Message.getSrc() method of the consumed 
message. Producer: The custom source org.jgroups.Address of the message to be 
sent.", "constantName": "org.apache.camel.compon [...]
+    "CamelJGroupsOriginalMessage": { "index": 3, "kind": "header", 
"displayName": "", "group": "common", "label": "", "required": false, 
"javaType": "org.jgroups.Message", "deprecated": false, "deprecationNote": "", 
"autowired": false, "secret": false, "description": "The original 
org.jgroups.Message instance from which the body of the consumed message has 
been extracted.", "constantName": 
"org.apache.camel.component.jgroups.JGroupsConstants#HEADER_JGROUPS_ORIGINAL_MESSAGE"
 }
   },
   "properties": {
     "clusterName": { "index": 0, "kind": "path", "displayName": "Cluster 
Name", "group": "common", "label": "", "required": true, "type": "string", 
"javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", 
"autowired": false, "secret": false, "description": "The name of the JGroups 
cluster the component should connect to." },
diff --git 
a/components/camel-jgroups/src/main/java/org/apache/camel/component/jgroups/JGroupsConstants.java
 
b/components/camel-jgroups/src/main/java/org/apache/camel/component/jgroups/JGroupsConstants.java
index 9ef48ef41411..e307baaae82b 100644
--- 
a/components/camel-jgroups/src/main/java/org/apache/camel/component/jgroups/JGroupsConstants.java
+++ 
b/components/camel-jgroups/src/main/java/org/apache/camel/component/jgroups/JGroupsConstants.java
@@ -24,24 +24,24 @@ public final class JGroupsConstants {
             Address (`org.jgroups.Address`) of the channel associated with the
             endpoint.""",
               javaType = "org.jgroups.Address")
-    public static final String HEADER_JGROUPS_CHANNEL_ADDRESS = 
"JGROUPS_CHANNEL_ADDRESS";
+    public static final String HEADER_JGROUPS_CHANNEL_ADDRESS = 
"CamelJGroupsChannelAddress";
     @Metadata(description = """
             *Consumer*: The `org.jgroups.Address` instance extracted by
             `org.jgroups.Message`.getDest() method of the consumed message.
             *Producer*: The custom destination `org.jgroups.Address` of the 
message to be sent.""",
               javaType = "org.jgroups.Address")
-    public static final String HEADER_JGROUPS_DEST = "JGROUPS_DEST";
+    public static final String HEADER_JGROUPS_DEST = "CamelJGroupsDest";
     @Metadata(description = """
             *Consumer* : The `org.jgroups.Address` instance extracted by
             `org.jgroups.Message`.getSrc() method of the consumed message.\s
             *Producer*: The custom source `org.jgroups.Address` of the message 
to be sent.""",
               javaType = "org.jgroups.Address")
-    public static final String HEADER_JGROUPS_SRC = "JGROUPS_SRC";
+    public static final String HEADER_JGROUPS_SRC = "CamelJGroupsSrc";
     @Metadata(description = """
             The original `org.jgroups.Message` instance from which the body of 
the
             consumed message has been extracted.""",
               javaType = "org.jgroups.Message")
-    public static final String HEADER_JGROUPS_ORIGINAL_MESSAGE = 
"JGROUPS_ORIGINAL_MESSAGE";
+    public static final String HEADER_JGROUPS_ORIGINAL_MESSAGE = 
"CamelJGroupsOriginalMessage";
 
     private JGroupsConstants() {
 
diff --git 
a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_21.adoc 
b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_21.adoc
index ccfecdbcc9aa..be7a8fae573c 100644
--- a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_21.adoc
+++ b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_21.adoc
@@ -307,6 +307,27 @@ previous code path silently produced `null` whenever a 
route mixed `converse` an
 calls. If you were not setting the guardrail identifier via header, the 
endpoint-level
 `guardrailIdentifier` option continues to work without changes.
 
+=== camel-jgroups
+
+The Exchange header constants in `JGroupsConstants` have been renamed to follow
+the Camel naming convention used across the rest of the component catalog. The
+Java field names are unchanged; only the header string values have changed:
+
+[options="header"]
+|===
+| Constant | Previous value | New value
+| `JGroupsConstants.HEADER_JGROUPS_CHANNEL_ADDRESS` | 
`JGROUPS_CHANNEL_ADDRESS` | `CamelJGroupsChannelAddress`
+| `JGroupsConstants.HEADER_JGROUPS_DEST` | `JGROUPS_DEST` | `CamelJGroupsDest`
+| `JGroupsConstants.HEADER_JGROUPS_SRC` | `JGROUPS_SRC` | `CamelJGroupsSrc`
+| `JGroupsConstants.HEADER_JGROUPS_ORIGINAL_MESSAGE` | 
`JGROUPS_ORIGINAL_MESSAGE` | `CamelJGroupsOriginalMessage`
+|===
+
+Routes that reference the constant symbolically (for example
+`setHeader(JGroupsConstants.HEADER_JGROUPS_DEST, ...)`) continue to work
+without changes. Routes that set the header by its literal string value
+(for example `setHeader("JGROUPS_DEST", ...)`) must be updated to use the
+new value (`setHeader("CamelJGroupsDest", ...)`).
+
 === camel-aws2-s3
 
 The `listObjects` operation now uses the `ListObjectsV2` AWS API instead of 
the deprecated `ListObjects` API.
diff --git 
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/JGroupsEndpointBuilderFactory.java
 
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/JGroupsEndpointBuilderFactory.java
index d4656526200a..aea6a7d318aa 100644
--- 
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/JGroupsEndpointBuilderFactory.java
+++ 
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/JGroupsEndpointBuilderFactory.java
@@ -420,10 +420,10 @@ public interface JGroupsEndpointBuilderFactory {
          * 
          * Group: common
          * 
-         * @return the name of the header {@code JGROUPS_CHANNEL_ADDRESS}.
+         * @return the name of the header {@code JGroupsChannelAddress}.
          */
-        public String jgroupsChannelAddress() {
-            return "JGROUPS_CHANNEL_ADDRESS";
+        public String jGroupsChannelAddress() {
+            return "CamelJGroupsChannelAddress";
         }
         /**
          * Consumer: The org.jgroups.Address instance extracted by
@@ -435,10 +435,10 @@ public interface JGroupsEndpointBuilderFactory {
          * 
          * Group: common
          * 
-         * @return the name of the header {@code JGROUPS_DEST}.
+         * @return the name of the header {@code JGroupsDest}.
          */
-        public String jgroupsDest() {
-            return "JGROUPS_DEST";
+        public String jGroupsDest() {
+            return "CamelJGroupsDest";
         }
         /**
          * Consumer : The org.jgroups.Address instance extracted by
@@ -450,10 +450,10 @@ public interface JGroupsEndpointBuilderFactory {
          * 
          * Group: common
          * 
-         * @return the name of the header {@code JGROUPS_SRC}.
+         * @return the name of the header {@code JGroupsSrc}.
          */
-        public String jgroupsSrc() {
-            return "JGROUPS_SRC";
+        public String jGroupsSrc() {
+            return "CamelJGroupsSrc";
         }
         /**
          * The original org.jgroups.Message instance from which the body of the
@@ -463,10 +463,10 @@ public interface JGroupsEndpointBuilderFactory {
          * 
          * Group: common
          * 
-         * @return the name of the header {@code JGROUPS_ORIGINAL_MESSAGE}.
+         * @return the name of the header {@code JGroupsOriginalMessage}.
          */
-        public String jgroupsOriginalMessage() {
-            return "JGROUPS_ORIGINAL_MESSAGE";
+        public String jGroupsOriginalMessage() {
+            return "CamelJGroupsOriginalMessage";
         }
     }
     static JGroupsEndpointBuilder endpointBuilder(String componentName, String 
path) {

Reply via email to