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 2023/03/30 06:14:50 UTC
[camel] 02/04: CAMEL-19222 - Camel-Azure-CosmosDB: make the itemPartitionKey a String instead of a pojo
This is an automated email from the ASF dual-hosted git repository.
acosentino pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
commit 4573e6e4c3def3a880b3ea15485e228bec70d4b2
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Thu Mar 30 08:02:09 2023 +0200
CAMEL-19222 - Camel-Azure-CosmosDB: make the itemPartitionKey a String instead of a pojo
Signed-off-by: Andrea Cosentino <an...@gmail.com>
---
.../apache/camel/component/azure/cosmosdb/CosmosDbConfiguration.java | 1 -
.../component/azure/cosmosdb/CosmosDbConfigurationOptionsProxy.java | 5 +++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/components/camel-azure/camel-azure-cosmosdb/src/main/java/org/apache/camel/component/azure/cosmosdb/CosmosDbConfiguration.java b/components/camel-azure/camel-azure-cosmosdb/src/main/java/org/apache/camel/component/azure/cosmosdb/CosmosDbConfiguration.java
index ee0ef3bca38..bb17deaf247 100644
--- a/components/camel-azure/camel-azure-cosmosdb/src/main/java/org/apache/camel/component/azure/cosmosdb/CosmosDbConfiguration.java
+++ b/components/camel-azure/camel-azure-cosmosdb/src/main/java/org/apache/camel/component/azure/cosmosdb/CosmosDbConfiguration.java
@@ -20,7 +20,6 @@ import com.azure.cosmos.ConsistencyLevel;
import com.azure.cosmos.CosmosAsyncClient;
import com.azure.cosmos.models.ChangeFeedProcessorOptions;
import com.azure.cosmos.models.CosmosQueryRequestOptions;
-import com.azure.cosmos.models.PartitionKey;
import com.azure.cosmos.models.ThroughputProperties;
import org.apache.camel.RuntimeCamelException;
import org.apache.camel.spi.Metadata;
diff --git a/components/camel-azure/camel-azure-cosmosdb/src/main/java/org/apache/camel/component/azure/cosmosdb/CosmosDbConfigurationOptionsProxy.java b/components/camel-azure/camel-azure-cosmosdb/src/main/java/org/apache/camel/component/azure/cosmosdb/CosmosDbConfigurationOptionsProxy.java
index 680e5c78eb7..7c22ccba580 100644
--- a/components/camel-azure/camel-azure-cosmosdb/src/main/java/org/apache/camel/component/azure/cosmosdb/CosmosDbConfigurationOptionsProxy.java
+++ b/components/camel-azure/camel-azure-cosmosdb/src/main/java/org/apache/camel/component/azure/cosmosdb/CosmosDbConfigurationOptionsProxy.java
@@ -94,8 +94,9 @@ public class CosmosDbConfigurationOptionsProxy {
}
public PartitionKey getItemPartitionKey(final Exchange exchange) {
- return new PartitionKey(getOption(exchange, CosmosDbConstants.ITEM_PARTITION_KEY, configuration::getItemPartitionKey,
- String.class));
+ return new PartitionKey(
+ getOption(exchange, CosmosDbConstants.ITEM_PARTITION_KEY, configuration::getItemPartitionKey,
+ String.class));
}
public Object getItem(final Exchange exchange) {