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

gnodet pushed a commit to branch camel-4.22.x
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/camel-4.22.x by this push:
     new e941e7785e1b [backport camel-4.22.x] CAMEL-24606: 
camel-google-firestore - document the realtime change type header (#26099)
e941e7785e1b is described below

commit e941e7785e1be8b544e66c42550424e9552a9e82
Author: Guillaume Nodet <[email protected]>
AuthorDate: Thu Sep 3 22:05:37 2026 +0200

    [backport camel-4.22.x] CAMEL-24606: camel-google-firestore - document the 
realtime change type header (#26099)
    
    Co-authored-by: github-actions[bot] 
<github-actions[bot]@users.noreply.github.com>
---
 .../apache/camel/catalog/components/google-firestore.json   |  5 +++--
 .../camel/component/google/firestore/google-firestore.json  |  5 +++--
 .../google/firestore/GoogleFirestoreConstants.java          |  6 ++++++
 .../component/google/firestore/GoogleFirestoreConsumer.java |  2 +-
 .../endpoint/dsl/GoogleFirestoreEndpointBuilderFactory.java | 13 +++++++++++++
 5 files changed, 26 insertions(+), 5 deletions(-)

diff --git 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/google-firestore.json
 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/google-firestore.json
index 76418a3e3ec1..88530f0eb12a 100644
--- 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/google-firestore.json
+++ 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/google-firestore.json
@@ -53,8 +53,9 @@
     "CamelGoogleFirestoreResponseCreateTime": { "index": 11, "kind": "header", 
"displayName": "", "group": "consumer", "label": "consumer", "required": false, 
"javaType": "com.google.cloud.Timestamp", "deprecated": false, 
"deprecationNote": "", "autowired": false, "secret": false, "description": "The 
document create time.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#RESPONSE_CREATE_TIME"
 },
     "CamelGoogleFirestoreResponseUpdateTime": { "index": 12, "kind": "header", 
"displayName": "", "group": "consumer", "label": "consumer", "required": false, 
"javaType": "com.google.cloud.Timestamp", "deprecated": false, 
"deprecationNote": "", "autowired": false, "secret": false, "description": "The 
document update time.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#RESPONSE_UPDATE_TIME"
 },
     "CamelGoogleFirestoreResponseReadTime": { "index": 13, "kind": "header", 
"displayName": "", "group": "consumer", "label": "consumer", "required": false, 
"javaType": "com.google.cloud.Timestamp", "deprecated": false, 
"deprecationNote": "", "autowired": false, "secret": false, "description": "The 
document read time.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#RESPONSE_READ_TIME"
 },
-    "CamelGoogleFirestoreMerge": { "index": 14, "kind": "header", 
"displayName": "", "group": "producer", "label": "producer", "required": false, 
"javaType": "Boolean", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "defaultValue": "false", "description": "When true, 
merge the data with existing document data instead of overwriting.", 
"constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#MERGE" },
-    "CamelGoogleFirestoreMergeFields": { "index": 15, "kind": "header", 
"displayName": "", "group": "producer", "label": "producer", "required": false, 
"javaType": "java.util.List<String>", "deprecated": false, "deprecationNote": 
"", "autowired": false, "secret": false, "description": "List of field paths to 
merge when using merge option.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#MERGE_FIELDS"
 }
+    "CamelGoogleFirestoreChangeType": { "index": 14, "kind": "header", 
"displayName": "", "group": "consumer", "label": "consumer", "required": false, 
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "The type of change reported by the 
realtime listener: ADDED, MODIFIED or REMOVED. Only set when realtimeUpdates is 
enabled.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#CHANGE_TYPE"
 },
+    "CamelGoogleFirestoreMerge": { "index": 15, "kind": "header", 
"displayName": "", "group": "producer", "label": "producer", "required": false, 
"javaType": "Boolean", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "defaultValue": "false", "description": "When true, 
merge the data with existing document data instead of overwriting.", 
"constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#MERGE" },
+    "CamelGoogleFirestoreMergeFields": { "index": 16, "kind": "header", 
"displayName": "", "group": "producer", "label": "producer", "required": false, 
"javaType": "java.util.List<String>", "deprecated": false, "deprecationNote": 
"", "autowired": false, "secret": false, "description": "List of field paths to 
merge when using merge option.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#MERGE_FIELDS"
 }
   },
   "properties": {
     "collectionName": { "index": 0, "kind": "path", "displayName": "Collection 
Name", "group": "common", "label": "common", "required": true, "type": 
"string", "javaType": "java.lang.String", "deprecated": false, 
"deprecationNote": "", "autowired": false, "secret": false, 
"configurationClass": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConfiguration", 
"configurationField": "configuration", "description": "The collection name to 
use" },
diff --git 
a/components/camel-google/camel-google-firestore/src/generated/resources/META-INF/org/apache/camel/component/google/firestore/google-firestore.json
 
b/components/camel-google/camel-google-firestore/src/generated/resources/META-INF/org/apache/camel/component/google/firestore/google-firestore.json
index 76418a3e3ec1..88530f0eb12a 100644
--- 
a/components/camel-google/camel-google-firestore/src/generated/resources/META-INF/org/apache/camel/component/google/firestore/google-firestore.json
+++ 
b/components/camel-google/camel-google-firestore/src/generated/resources/META-INF/org/apache/camel/component/google/firestore/google-firestore.json
@@ -53,8 +53,9 @@
     "CamelGoogleFirestoreResponseCreateTime": { "index": 11, "kind": "header", 
"displayName": "", "group": "consumer", "label": "consumer", "required": false, 
"javaType": "com.google.cloud.Timestamp", "deprecated": false, 
"deprecationNote": "", "autowired": false, "secret": false, "description": "The 
document create time.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#RESPONSE_CREATE_TIME"
 },
     "CamelGoogleFirestoreResponseUpdateTime": { "index": 12, "kind": "header", 
"displayName": "", "group": "consumer", "label": "consumer", "required": false, 
"javaType": "com.google.cloud.Timestamp", "deprecated": false, 
"deprecationNote": "", "autowired": false, "secret": false, "description": "The 
document update time.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#RESPONSE_UPDATE_TIME"
 },
     "CamelGoogleFirestoreResponseReadTime": { "index": 13, "kind": "header", 
"displayName": "", "group": "consumer", "label": "consumer", "required": false, 
"javaType": "com.google.cloud.Timestamp", "deprecated": false, 
"deprecationNote": "", "autowired": false, "secret": false, "description": "The 
document read time.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#RESPONSE_READ_TIME"
 },
-    "CamelGoogleFirestoreMerge": { "index": 14, "kind": "header", 
"displayName": "", "group": "producer", "label": "producer", "required": false, 
"javaType": "Boolean", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "defaultValue": "false", "description": "When true, 
merge the data with existing document data instead of overwriting.", 
"constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#MERGE" },
-    "CamelGoogleFirestoreMergeFields": { "index": 15, "kind": "header", 
"displayName": "", "group": "producer", "label": "producer", "required": false, 
"javaType": "java.util.List<String>", "deprecated": false, "deprecationNote": 
"", "autowired": false, "secret": false, "description": "List of field paths to 
merge when using merge option.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#MERGE_FIELDS"
 }
+    "CamelGoogleFirestoreChangeType": { "index": 14, "kind": "header", 
"displayName": "", "group": "consumer", "label": "consumer", "required": false, 
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "description": "The type of change reported by the 
realtime listener: ADDED, MODIFIED or REMOVED. Only set when realtimeUpdates is 
enabled.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#CHANGE_TYPE"
 },
+    "CamelGoogleFirestoreMerge": { "index": 15, "kind": "header", 
"displayName": "", "group": "producer", "label": "producer", "required": false, 
"javaType": "Boolean", "deprecated": false, "deprecationNote": "", "autowired": 
false, "secret": false, "defaultValue": "false", "description": "When true, 
merge the data with existing document data instead of overwriting.", 
"constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#MERGE" },
+    "CamelGoogleFirestoreMergeFields": { "index": 16, "kind": "header", 
"displayName": "", "group": "producer", "label": "producer", "required": false, 
"javaType": "java.util.List<String>", "deprecated": false, "deprecationNote": 
"", "autowired": false, "secret": false, "description": "List of field paths to 
merge when using merge option.", "constantName": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConstants#MERGE_FIELDS"
 }
   },
   "properties": {
     "collectionName": { "index": 0, "kind": "path", "displayName": "Collection 
Name", "group": "common", "label": "common", "required": true, "type": 
"string", "javaType": "java.lang.String", "deprecated": false, 
"deprecationNote": "", "autowired": false, "secret": false, 
"configurationClass": 
"org.apache.camel.component.google.firestore.GoogleFirestoreConfiguration", 
"configurationField": "configuration", "description": "The collection name to 
use" },
diff --git 
a/components/camel-google/camel-google-firestore/src/main/java/org/apache/camel/component/google/firestore/GoogleFirestoreConstants.java
 
b/components/camel-google/camel-google-firestore/src/main/java/org/apache/camel/component/google/firestore/GoogleFirestoreConstants.java
index 904409f5ef09..bd56c9437b12 100644
--- 
a/components/camel-google/camel-google-firestore/src/main/java/org/apache/camel/component/google/firestore/GoogleFirestoreConstants.java
+++ 
b/components/camel-google/camel-google-firestore/src/main/java/org/apache/camel/component/google/firestore/GoogleFirestoreConstants.java
@@ -73,6 +73,12 @@ public final class GoogleFirestoreConstants {
     @Metadata(label = "consumer", description = "The document read time.", 
javaType = "com.google.cloud.Timestamp")
     public static final String RESPONSE_READ_TIME = 
"CamelGoogleFirestoreResponseReadTime";
 
+    @Metadata(label = "consumer",
+              description = "The type of change reported by the realtime 
listener: ADDED, MODIFIED or REMOVED."
+                            + " Only set when realtimeUpdates is enabled.",
+              javaType = "String")
+    public static final String CHANGE_TYPE = "CamelGoogleFirestoreChangeType";
+
     // Set/update options
     @Metadata(label = "producer", description = "When true, merge the data 
with existing document data instead of overwriting.",
               javaType = "Boolean", defaultValue = "false")
diff --git 
a/components/camel-google/camel-google-firestore/src/main/java/org/apache/camel/component/google/firestore/GoogleFirestoreConsumer.java
 
b/components/camel-google/camel-google-firestore/src/main/java/org/apache/camel/component/google/firestore/GoogleFirestoreConsumer.java
index d39188edb737..07adb86a5330 100644
--- 
a/components/camel-google/camel-google-firestore/src/main/java/org/apache/camel/component/google/firestore/GoogleFirestoreConsumer.java
+++ 
b/components/camel-google/camel-google-firestore/src/main/java/org/apache/camel/component/google/firestore/GoogleFirestoreConsumer.java
@@ -166,7 +166,7 @@ public class GoogleFirestoreConsumer extends 
ScheduledBatchPollingConsumer {
         message.setHeader(GoogleFirestoreConstants.RESPONSE_READ_TIME, 
document.getReadTime());
 
         if (changeType != null) {
-            message.setHeader("CamelGoogleFirestoreChangeType", 
changeType.name());
+            message.setHeader(GoogleFirestoreConstants.CHANGE_TYPE, 
changeType.name());
         }
 
         return exchange;
diff --git 
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/GoogleFirestoreEndpointBuilderFactory.java
 
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/GoogleFirestoreEndpointBuilderFactory.java
index 72e3b7a18e6b..032683365cec 100644
--- 
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/GoogleFirestoreEndpointBuilderFactory.java
+++ 
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/GoogleFirestoreEndpointBuilderFactory.java
@@ -1342,6 +1342,19 @@ public interface GoogleFirestoreEndpointBuilderFactory {
         public String googleFirestoreResponseReadTime() {
             return "CamelGoogleFirestoreResponseReadTime";
         }
+        /**
+         * The type of change reported by the realtime listener: ADDED, 
MODIFIED
+         * or REMOVED. Only set when realtimeUpdates is enabled.
+         * 
+         * The option is a: {@code String} type.
+         * 
+         * Group: consumer
+         * 
+         * @return the name of the header {@code GoogleFirestoreChangeType}.
+         */
+        public String googleFirestoreChangeType() {
+            return "CamelGoogleFirestoreChangeType";
+        }
         /**
          * When true, merge the data with existing document data instead of
          * overwriting.

Reply via email to