From b8e20f60958bad2a3eda77c0fa02e11bda07d91d Mon Sep 17 00:00:00 2001 From: Christian Leinweber Date: Wed, 5 May 2021 00:26:38 +0200 Subject: [PATCH] add legacy checkpointing description to checkpointStrategy parameter on event-hub Signed-off-by: Christian Leinweber --- content/docs/2.3/scalers/azure-event-hub.md | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/content/docs/2.3/scalers/azure-event-hub.md b/content/docs/2.3/scalers/azure-event-hub.md index e396de4c3..5d683e1b4 100644 --- a/content/docs/2.3/scalers/azure-event-hub.md +++ b/content/docs/2.3/scalers/azure-event-hub.md @@ -29,13 +29,17 @@ triggers: - `storageConnectionFromEnv` - Name of the environment variable that provides connection string for Azure Storage Account to store checkpoint. As of now the Event Hub scaler only reads from Azure Blob Storage. - `consumerGroup` - Consumer group of Event Hub consumer. (default: `$default`) - `unprocessedEventThreshold` - : Average target value to trigger scaling actions. (default: 64) -- `blobContainer` - Container name to store checkpoint. This is needed when a using an Event Hub application written in .net or Java, and not Azure Functions. +- `blobContainer` - Container name to store checkpoint. This is needed for every `checkpointStrategy` except of `AzureFunction`. With Azure Functions the `blobContainer` is autogenerated and cannot be overridden. - `checkpointStrategy` - configure the checkpoint behaviour of different Event Hub SDK's. (default: `""`) - - `""`: the default behaviour works for C#, older Python and Java eventhub implementations if a `blobContainer` is configured. - - `azureFunction`: suitable for Azure Functions. This is the default setting, if `blobcontainer` is empty. - - `blobMetadata`: For all implementations which stores checkpoint informations on blob metadata and not as blob content like current Python and Java Event Hub SDK's. + - `""`: if no checkpointStrategy is specified, the Event Hub scaler is in backward compatibility mode and able to scale older implementations of C# , Python or Java Event Hub SDK's. (see "Legacy checkpointing"). if this behaviour should be used, `blobContainer` is also required. + - `azureFunction`: suitable for Azure Functions. This is automatically the default setting, if `blobcontainer` is empty. + - `blobMetadata`: For all implementations which stores checkpoint informations on blob metadata like current C#, Python, Java and JavaScript Event Hub SDK's. - `goSdk` For all implementations which use the Golang SDK checkpointing like Dapr.io +**Legacy checkpointing** +C# applications, which use the `Microsoft.Azure.EventHubs` package, Java applications which use the `azure-eventhubs-eph` package or Python applications which use the `azure-eventhub` below `v5` are supported if no `checkpointStrategy`is specified. All these legacy implementations based on the `EventProcessorHost` Client, which stores checkpoint information as blobcontainer content + +C# Applications which use the current `Azure.Messaging.EventHubs` package, Java applications which use the current `azure-messaging-eventhubs` package or Python applications since `azure-eventhub v5`, have to set the `checkpointStrategy`to `blobMetadata`. All these implementations based on the `EventProcessorClient` which stores checkpoint information as blobcontainer metadata. ### Authentication Parameters The common way of authenticating to Azure Event Hub is by using the connection string. However, you can use [Pod Identity](https://azure.github.io/aad-pod-identity/docs/demo/standard_walkthrough/) if you host your cluster in Azure AKS, and if have configured it to support Pod Identity.