Configure Event Hubs with Microsoft Purview to send and receive Atlas Kafka topics messages
This article will show you how to configure Microsoft Purview to be able to send and receive Atlas Kafka topics events with Azure Event Hubs.
If you have already configured your environment, you can follow our guide to get started with the Azure.Messaging.EventHubs .NET library to send and receive messages.
Prerequisites
To configure your environment, you need certain prerequisites in place:
- A Microsoft Azure subscription. To use Azure services, including Event Hubs, you need an Azure subscription. If you don't have an Azure account, you can sign up for a free trial or use your MSDN subscriber benefits when you create an account.
- An active Microsoft Purview account.
- An Azure Event Hubs namespace with an Event Hubs.
Configure Event Hubs
To send or receive Atlas Kafka topics messages, you'll need to configure at least one Event Hubs namespace.
Note
If your Microsoft Purview account was created before December 15th, 2022 you may have a managed Event Hubs resource already associated with your account.
You can check in Managed Resources under settings on your Microsoft Purview account page in the Azure portal.
If you do not see this resource, or it is disabled, follow the steps below to configure your Event Hubs.
If it is enabled, you can continue to use this managed Event Hubs namespace if you prefer. (There is associated cost. See see the pricing page.) If you want to manage your own Event Hubs account, you must first disable this feature and follow the steps below. If you disable the managed Event Hubs resource you won't be able to re-enable a managed Event Hub resource. You will only be able to configure your own Event Hubs.
Event Hubs permissions
To authenticate with your Event Hubs, you can either use:
- Microsoft Purview managed identity
- User assigned managed identity - only available when configuring namespaces after account creation.
One of these identities will need at least contributor permissions on your Event Hubs to be able to configure them to use with Microsoft Purview.
Configure Event Hubs to publish messages to Microsoft Purview
Navigate to Kafka configuration under settings on your Microsoft Purview account page in the Azure portal.
Select Add configuration and Hook configuration.
Note
You can add as many hook configurations as you need.
Give a name to your hook configuration, select your subscription, an existing Event Hubs namespace, an existing Event Hubs to send the notifications to, the consumer group you want to use, and the kind of authentication you would like to use.
Tip
You can use the same Event Hubs namespace more than once, but each configuration will need its own Event Hubs.
Select Save. It will take a couple minutes for your configuration to complete.
Once configuration is complete, you can begin the steps to publish messages to Microsoft Purview.
Configure Event Hubs to receive messages from Microsoft Purview
Navigate to Kafka configuration under settings on your Microsoft Purview account page in the Azure portal.
If there's a configuration already listed as type Notification, Event Hubs is already configured, and you can begin the steps to receive Microsoft Purview messages.
Note
Only one Notification Event Hubs can be configured at a time.
If there isn't a Notification configuration already listed, select Add configuration and Notification configuration.
Give a name to your notification configuration, select your subscription, an existing Event Hubs namespace, an existing Event Hubs to send the notifications to, the partitions you want to use, and the kind of authentication you would like to use.
Tip
You can use the same Event Hubs namespace more than once, but each configuration will need its own Event Hubs.
Select Save. It will take a couple minutes for your configuration to complete.
Once configuration is complete, you can begin the steps to receive Microsoft Purview messages.
Remove configured Event Hubs
To remove configured Event Hubs namespaces, you can follow these steps:
- Search for and open your Microsoft Purview account in the Azure portal.
- Select Kafka configuration under settings on your Microsoft Purview account page in the Azure portal.
- Select the Event Hubs you want to disable. (Hook hubs send messages to Microsoft Purview. Notification hubs receive notifications.)
- Select Remove to save the choice and begin the disablement process. This can take several minutes to complete.
Next steps
Feedback
Submit and view feedback for