diff --git a/kamelets/azure-cosmosdb-sink.kamelet.yaml b/kamelets/azure-cosmosdb-sink.kamelet.yaml
index a45cc6671..29421a059 100644
--- a/kamelets/azure-cosmosdb-sink.kamelet.yaml
+++ b/kamelets/azure-cosmosdb-sink.kamelet.yaml
@@ -37,10 +37,13 @@ spec:
In the headers, you can optionally set the `itemPartitionKey` / `ce-itemPartitionKey` property to specify the partition key for a specific item.
If you do not set the property in the header, you'll need to use the static property itemPartitonKey.
+
+ There are two different mechanism of authentication `SHARED_ACCOUNT_KEY` and `AZURE_IDENTITY`, you could specify with credentialType property. If you're using `SHARED_ACCOUNT_KEY` accountKey property will be needed.
+
+ In case of `AZURE_IDENTITY` selection, the DefaultAzureCredential will attempt to authenticate via the following mechanisms in the following order enviroment, Workload Identity, Managed Identity, Azure Developer CLI, IntelliJ, Azure CLI and Azure Powershell.
required:
- databaseName
- containerName
- - accountKey
- databaseEndpoint
type: object
properties:
@@ -67,6 +70,12 @@ spec:
title: Item Partition Key
description: Represents a partition key value in the Azure Cosmos DB database service. A partition key identifies the partition where the item is stored in.
type: string
+ credentialType:
+ title: Credential Type
+ description: Determines the credential strategy to adopt.
+ type: string
+ enum: ["SHARED_ACCOUNT_KEY", "AZURE_IDENTITY"]
+ default: "SHARED_ACCOUNT_KEY"
types:
in:
mediaType: application/json
@@ -102,8 +111,9 @@ spec:
- to:
uri: "azure-cosmosdb:{{databaseName}}/{{containerName}}"
parameters:
- accountKey: "{{accountKey}}"
+ accountKey: "{{?accountKey}}"
databaseEndpoint: "{{databaseEndpoint}}"
itemPartitionKey: "{{?itemPartitionKey}}"
operation: createItem
+ credentialType: "{{credentialType}}"
diff --git a/kamelets/azure-cosmosdb-source.kamelet.yaml b/kamelets/azure-cosmosdb-source.kamelet.yaml
index bcd2b335e..f94196095 100644
--- a/kamelets/azure-cosmosdb-source.kamelet.yaml
+++ b/kamelets/azure-cosmosdb-source.kamelet.yaml
@@ -32,11 +32,14 @@ spec:
definition:
title: "Azure CosmosDB Source"
description: |-
- Consume Changes from a CosmosDB instance
+ Consume Changes from a CosmosDB instance.
+
+ There are two different mechanism of authentication `SHARED_ACCOUNT_KEY` and `AZURE_IDENTITY`, you could specify with credentialType property. If you're using `SHARED_ACCOUNT_KEY` accountKey property will be needed.
+
+ In case of `AZURE_IDENTITY` selection, the DefaultAzureCredential will attempt to authenticate via the following mechanisms in the following order enviroment, Workload Identity, Managed Identity, Azure Developer CLI, IntelliJ, Azure CLI and Azure Powershell.
required:
- databaseName
- containerName
- - accountKey
- databaseEndpoint
type: object
properties:
@@ -77,6 +80,12 @@ spec:
title: Database Endpoint
description: Sets the Azure Cosmos database endpoint the component will connect to.
type: string
+ credentialType:
+ title: Credential Type
+ description: Determines the credential strategy to adopt.
+ type: string
+ enum: ["SHARED_ACCOUNT_KEY", "AZURE_IDENTITY"]
+ default: "SHARED_ACCOUNT_KEY"
types:
out:
mediaType: application/json
@@ -90,10 +99,11 @@ spec:
parameters:
leaseDatabaseName: "{{?leaseDatabaseName}}"
leaseContainerName: "{{?leaseContainerName}}"
- accountKey: "{{accountKey}}"
+ accountKey: "{{?accountKey}}"
createLeaseDatabaseIfNotExists: "{{createLeaseDatabaseIfNotExists}}"
createLeaseContainerIfNotExists: "{{createLeaseContainerIfNotExists}}"
databaseEndpoint: "{{databaseEndpoint}}"
+ credentialType: "{{credentialType}}"
steps:
- marshal:
json: {}
diff --git a/library/camel-kamelets-catalog/src/test/java/org/apache/camel/kamelets/catalog/KameletsCatalogTest.java b/library/camel-kamelets-catalog/src/test/java/org/apache/camel/kamelets/catalog/KameletsCatalogTest.java
index abb5b9957..993a7fd6f 100644
--- a/library/camel-kamelets-catalog/src/test/java/org/apache/camel/kamelets/catalog/KameletsCatalogTest.java
+++ b/library/camel-kamelets-catalog/src/test/java/org/apache/camel/kamelets/catalog/KameletsCatalogTest.java
@@ -138,7 +138,7 @@ void testAllKameletDependencies() throws Exception {
void testSupportedHeaders() throws Exception {
verifyHeaders("aws-s3-source", 20);
verifyHeaders("aws-s3-sink", 27);
- verifyHeaders("aws-cloudtrail-source", 0);
+ verifyHeaders("aws-cloudtrail-source", 4);
verifyHeaders("aws-redshift-source", 0);
verifyHeaders("aws-not-exists", 0);
verifyHeaders("azure-eventhubs-sink", 2);
diff --git a/library/camel-kamelets/src/main/resources/kamelets/azure-cosmosdb-sink.kamelet.yaml b/library/camel-kamelets/src/main/resources/kamelets/azure-cosmosdb-sink.kamelet.yaml
index a45cc6671..29421a059 100644
--- a/library/camel-kamelets/src/main/resources/kamelets/azure-cosmosdb-sink.kamelet.yaml
+++ b/library/camel-kamelets/src/main/resources/kamelets/azure-cosmosdb-sink.kamelet.yaml
@@ -37,10 +37,13 @@ spec:
In the headers, you can optionally set the `itemPartitionKey` / `ce-itemPartitionKey` property to specify the partition key for a specific item.
If you do not set the property in the header, you'll need to use the static property itemPartitonKey.
+
+ There are two different mechanism of authentication `SHARED_ACCOUNT_KEY` and `AZURE_IDENTITY`, you could specify with credentialType property. If you're using `SHARED_ACCOUNT_KEY` accountKey property will be needed.
+
+ In case of `AZURE_IDENTITY` selection, the DefaultAzureCredential will attempt to authenticate via the following mechanisms in the following order enviroment, Workload Identity, Managed Identity, Azure Developer CLI, IntelliJ, Azure CLI and Azure Powershell.
required:
- databaseName
- containerName
- - accountKey
- databaseEndpoint
type: object
properties:
@@ -67,6 +70,12 @@ spec:
title: Item Partition Key
description: Represents a partition key value in the Azure Cosmos DB database service. A partition key identifies the partition where the item is stored in.
type: string
+ credentialType:
+ title: Credential Type
+ description: Determines the credential strategy to adopt.
+ type: string
+ enum: ["SHARED_ACCOUNT_KEY", "AZURE_IDENTITY"]
+ default: "SHARED_ACCOUNT_KEY"
types:
in:
mediaType: application/json
@@ -102,8 +111,9 @@ spec:
- to:
uri: "azure-cosmosdb:{{databaseName}}/{{containerName}}"
parameters:
- accountKey: "{{accountKey}}"
+ accountKey: "{{?accountKey}}"
databaseEndpoint: "{{databaseEndpoint}}"
itemPartitionKey: "{{?itemPartitionKey}}"
operation: createItem
+ credentialType: "{{credentialType}}"
diff --git a/library/camel-kamelets/src/main/resources/kamelets/azure-cosmosdb-source.kamelet.yaml b/library/camel-kamelets/src/main/resources/kamelets/azure-cosmosdb-source.kamelet.yaml
index bcd2b335e..f94196095 100644
--- a/library/camel-kamelets/src/main/resources/kamelets/azure-cosmosdb-source.kamelet.yaml
+++ b/library/camel-kamelets/src/main/resources/kamelets/azure-cosmosdb-source.kamelet.yaml
@@ -32,11 +32,14 @@ spec:
definition:
title: "Azure CosmosDB Source"
description: |-
- Consume Changes from a CosmosDB instance
+ Consume Changes from a CosmosDB instance.
+
+ There are two different mechanism of authentication `SHARED_ACCOUNT_KEY` and `AZURE_IDENTITY`, you could specify with credentialType property. If you're using `SHARED_ACCOUNT_KEY` accountKey property will be needed.
+
+ In case of `AZURE_IDENTITY` selection, the DefaultAzureCredential will attempt to authenticate via the following mechanisms in the following order enviroment, Workload Identity, Managed Identity, Azure Developer CLI, IntelliJ, Azure CLI and Azure Powershell.
required:
- databaseName
- containerName
- - accountKey
- databaseEndpoint
type: object
properties:
@@ -77,6 +80,12 @@ spec:
title: Database Endpoint
description: Sets the Azure Cosmos database endpoint the component will connect to.
type: string
+ credentialType:
+ title: Credential Type
+ description: Determines the credential strategy to adopt.
+ type: string
+ enum: ["SHARED_ACCOUNT_KEY", "AZURE_IDENTITY"]
+ default: "SHARED_ACCOUNT_KEY"
types:
out:
mediaType: application/json
@@ -90,10 +99,11 @@ spec:
parameters:
leaseDatabaseName: "{{?leaseDatabaseName}}"
leaseContainerName: "{{?leaseContainerName}}"
- accountKey: "{{accountKey}}"
+ accountKey: "{{?accountKey}}"
createLeaseDatabaseIfNotExists: "{{createLeaseDatabaseIfNotExists}}"
createLeaseContainerIfNotExists: "{{createLeaseContainerIfNotExists}}"
databaseEndpoint: "{{databaseEndpoint}}"
+ credentialType: "{{credentialType}}"
steps:
- marshal:
json: {}
diff --git a/pom.xml b/pom.xml
index 2c3cdf352..94e4b37a8 100644
--- a/pom.xml
+++ b/pom.xml
@@ -23,7 +23,7 @@
org.apache.camel
camel-dependencies
- 4.3.0
+ 4.4.0-SNAPSHOT
org.apache.camel.kamelets
@@ -62,7 +62,7 @@
0.16
2.7.11
- 4.3.0
+ 4.4.0-SNAPSHOT
2.2.0
4.1.0