azureazure-functionsazure-eventhubazure-stream-analytics

How to Copy Data from primary eventhub to secondary


I am exploring about the data transfer from one eventhub to another eventhub but both are paired using Geo-Recovery since it wont replicate the data from primary to secondary want to copy the message data from primary eventhub to secondary how it practically possible by following approaches. can some one help me to get some information

  1. Stream Analytics
  2. Azure Function Apps
  3. https://github.com/Azure-Samples/azure-messaging-replication-dotnet/blob/main/functions/config/EventHubCopy/README.md

Solution

  • Geo-Disaster Recovery (Geo-DR) in Azure Event Hubs is used to ensure high availability and resilience in the event of a regional outage or disaster. Geo-DR does not replicate data between the primary and secondary namespaces.

    enter image description here

    From the MSDOC The feature enables instantaneous continuity of operations with the same configuration, but does not replicate the event data.

    enter image description here

    Using Geo-Recovery for replicate the data from primary to secondary want to copy the message data from primary eventhub to secondary is not possible . Since we have read-only access to the secondary namespace. Secondary namespace is read-only. So we can use different Event Hub in order to copy other than secondary.

    I Used this MSDOC to Event replication tasks using Azure Event Hubs

    The code for Azure Messaging Replication Tasks with .NET in azure function app taken from git

    The below Function App code in git for processing data from a source Event Hub and sending it to a target Event Hub .

    Using Azure Function : enter image description here

    I refer this MSDOC for Process data using Stream Analytics with Azure Event Hubs