You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2022/10/13 07:56:26 UTC

[camel-kamelets] 02/06: Duplicate some of headers with a different name - Azure Storage Blob Source

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

acosentino pushed a commit to branch dupli-headers-az-storage-blob-source
in repository https://gitbox.apache.org/repos/asf/camel-kamelets.git

commit 29d912af5a048b5c533087f03d539232f8d1e582
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Thu Oct 13 09:35:27 2022 +0200

    Duplicate some of headers with a different name - Azure Storage Blob Source
---
 kamelets/azure-storage-blob-source.kamelet.yaml             |  4 +++-
 .../kamelets/azure-storage-blob-source.kamelet.yaml         | 13 +++++++++++++
 2 files changed, 16 insertions(+), 1 deletion(-)

diff --git a/kamelets/azure-storage-blob-source.kamelet.yaml b/kamelets/azure-storage-blob-source.kamelet.yaml
index 57fe7e1f..15b9d070 100644
--- a/kamelets/azure-storage-blob-source.kamelet.yaml
+++ b/kamelets/azure-storage-blob-source.kamelet.yaml
@@ -70,7 +70,7 @@ spec:
     - "github:apache.camel-kamelets:camel-kamelets-utils:main-SNAPSHOT"
   template:
     beans:
-      - name: renameHeaders
+      - name: duplicateHeaders
         type: "#class:org.apache.camel.kamelets.utils.headers.DuplicateNamingHeaders"
         property:
           - key: prefix
@@ -87,6 +87,8 @@ spec:
         accessKey: "{{accessKey}}"
         credentialType: "{{credentialType}}"
       steps:
+        - process:
+            ref: "{{duplicateHeaders}}"
         - to: "kamelet:sink"
         - to:
             uri: "azure-storage-blob:{{accountName}}/{{containerName}}"
diff --git a/library/camel-kamelets/src/main/resources/kamelets/azure-storage-blob-source.kamelet.yaml b/library/camel-kamelets/src/main/resources/kamelets/azure-storage-blob-source.kamelet.yaml
index 14eee2fb..57fe7e1f 100644
--- a/library/camel-kamelets/src/main/resources/kamelets/azure-storage-blob-source.kamelet.yaml
+++ b/library/camel-kamelets/src/main/resources/kamelets/azure-storage-blob-source.kamelet.yaml
@@ -67,7 +67,20 @@ spec:
     - "camel:core"
     - "camel:jsonpath"
     - "camel:timer"
+    - "github:apache.camel-kamelets:camel-kamelets-utils:main-SNAPSHOT"
   template:
+    beans:
+      - name: renameHeaders
+        type: "#class:org.apache.camel.kamelets.utils.headers.DuplicateNamingHeaders"
+        property:
+          - key: prefix
+            value: 'CamelAzureStorageBlob'
+          - key: renamingPrefix
+            value: 'azure.storage.blob.'
+          - key: mode
+            value: 'filtering'
+          - key: selectedHeaders
+            value: 'CamelAzureStorageBlobETag,CamelAzureStorageBlobCreationTime,CamelAzureStorageBlobLastModified,CamelAzureStorageBlobBlobSize'
     from:
       uri: "azure-storage-blob:{{accountName}}/{{containerName}}"
       parameters: