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 bcbfdfda054b [backport camel-4.22.x] CAMEL-25227: 
camel-azure-eventhubs - the partition key and id are looked up separately 
(#27437)
bcbfdfda054b is described below

commit bcbfdfda054b23a2bc365b9f332d241eef4838ab
Author: Andrea Cosentino <[email protected]>
AuthorDate: Tue Oct 6 13:30:43 2026 +0200

    [backport camel-4.22.x] CAMEL-25227: camel-azure-eventhubs - the partition 
key and id are looked up separately (#27437)
    
    CAMEL-25227: camel-azure-eventhubs - the partition key and id are looked up 
separately
    
    Backport of the component-doc part of #27381: a partition id header set by
    the route together with a partitionKey endpoint option, or a partition key
    header together with a partitionId option, selects both, and the producer
    fails with "Both partitionKey and partitionId are set".
    
    Signed-off-by: Andrea Cosentino <[email protected]>
    Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]>
---
 .../apache/camel/catalog/docs/azure-eventhubs-component.adoc   | 10 +++++++---
 .../src/main/docs/azure-eventhubs-component.adoc               | 10 +++++++---
 2 files changed, 14 insertions(+), 6 deletions(-)

diff --git 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/azure-eventhubs-component.adoc
 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/azure-eventhubs-component.adoc
index 79cb97975367..0ac28e852335 100644
--- 
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/azure-eventhubs-component.adoc
+++ 
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/docs/azure-eventhubs-component.adoc
@@ -191,9 +191,13 @@ The producer sends the events to the partition chosen, in 
this order, by:
 . the partition key of the event received by an `azure-eventhubs` consumer 
earlier in the route, so that events with
 the same key stay together
 
-Otherwise, Event Hubs picks the partition. The consumer sets the same two 
headers on every event it receives. While
-they still hold the received values, the producer does not take them as a 
partition chosen by the route, and it never
-reuses the partition id of a received event, because partitions differ from 
one Event Hub to another.
+Otherwise, Event Hubs picks the partition. The partition key and the partition 
id are looked up separately, so a
+partition id header set by the route together with a `partitionKey` endpoint 
option, or a partition key header together
+with a `partitionId` option, selects both, and the producer fails with `Both 
partitionKey and partitionId are set`.
+
+The consumer sets the same two headers on every event it receives. While they 
still hold the received values, the
+producer does not take them as a partition chosen by the route, and it never 
reuses the partition id of a received
+event, because partitions differ from one Event Hub to another.
 
 To keep the partition of the received event, for example when mirroring 
between Event Hubs that have the same
 partitions, remove the `CamelAzureEventHubsReceivedPartitionId` exchange 
property, or
diff --git 
a/components/camel-azure/camel-azure-eventhubs/src/main/docs/azure-eventhubs-component.adoc
 
b/components/camel-azure/camel-azure-eventhubs/src/main/docs/azure-eventhubs-component.adoc
index 79cb97975367..0ac28e852335 100644
--- 
a/components/camel-azure/camel-azure-eventhubs/src/main/docs/azure-eventhubs-component.adoc
+++ 
b/components/camel-azure/camel-azure-eventhubs/src/main/docs/azure-eventhubs-component.adoc
@@ -191,9 +191,13 @@ The producer sends the events to the partition chosen, in 
this order, by:
 . the partition key of the event received by an `azure-eventhubs` consumer 
earlier in the route, so that events with
 the same key stay together
 
-Otherwise, Event Hubs picks the partition. The consumer sets the same two 
headers on every event it receives. While
-they still hold the received values, the producer does not take them as a 
partition chosen by the route, and it never
-reuses the partition id of a received event, because partitions differ from 
one Event Hub to another.
+Otherwise, Event Hubs picks the partition. The partition key and the partition 
id are looked up separately, so a
+partition id header set by the route together with a `partitionKey` endpoint 
option, or a partition key header together
+with a `partitionId` option, selects both, and the producer fails with `Both 
partitionKey and partitionId are set`.
+
+The consumer sets the same two headers on every event it receives. While they 
still hold the received values, the
+producer does not take them as a partition chosen by the route, and it never 
reuses the partition id of a received
+event, because partitions differ from one Event Hub to another.
 
 To keep the partition of the received event, for example when mirroring 
between Event Hubs that have the same
 partitions, remove the `CamelAzureEventHubsReceivedPartitionId` exchange 
property, or

Reply via email to