How to set the Event Hub partition key per-event using "Send Multiple Events" action?
I am using Logic Apps Standard. Iterating and sending individual events using the Azure Event Hubs "Send Event" action does not give me acceptable performance.
Switching to "Send Multiple Events" (InApp) action in a stateless workflow is better, but for some inexplicable reason I can only specify a single partition key value for the whole batch.
I have prepped the events into an array using the Select action. And I can then provide the entire array to "Send Multiple Events". But how can I specify the partition keys for those events? The objects in the array include the required properties.
EDIT: In fact, the partitionKey property seems to be ignored altogether.
{
"type": "ServiceProvider",
"inputs": {
"parameters": {
"eventHubName": "logexample",
"eventDatas": "@body('Select_Events')",
"partitionKey": "hardcoded"
},
"serviceProviderConfiguration": {
"connectionName": "eventHub",
"operationId": "sendEvents",
"serviceProviderId": "/serviceProviders/eventHub"
}
}
}
In the example above the Select_Event body holds an array of events mapped to the ContentData property. Also, I've hard-coded the partition key value to make sure that they all end up in the same partition - even on subsequent invocations. However, this does not happen. What am I getting wrong?