Creating Azure Event Hubs Namespaces
A namespace is a container for all Event Hubs resources. You need to create a namespace before you can create any Event Hubs or other Event Hubs entities within it. This guide walks you through the process of creating a new Event Hubs namespace using the Azure portal.
Prerequisites
- An Azure subscription. If you don't have one, you can sign up for a free trial.
- Access to the Azure portal.
Steps to Create a Namespace
-
Sign in to the Azure portal: Navigate to https://portal.azure.com/ and sign in with your Azure account.
-
Search for Event Hubs: In the Azure portal search bar at the top, type "Event Hubs" and select "Event Hubs" from the search results.
-
Create Namespace: On the Event Hubs page, click the + Create button.
-
Configure Basic Settings:
- Subscription: Select the Azure subscription you want to use.
- Resource group: Choose an existing resource group or create a new one by clicking "Create new". A resource group is a logical container for your Azure resources.
- Namespace name: Enter a globally unique name for your Event Hubs namespace. This name will be part of the namespace's endpoint URL.
- Region: Select the Azure region where you want to deploy your namespace. Choose a region geographically close to your applications or consumers for lower latency.
- Pricing tier: Select the appropriate pricing tier. The Standard tier is recommended for most production scenarios, offering features like auto-inflate and capture. The Basic tier is suitable for development and testing.
-
Configure Networking (Optional): You can configure network access settings here. For initial setup, you can leave this as default (public endpoint).
-
Configure Advanced Settings (Optional):
- Enable auto-inflate: This feature allows Event Hubs to automatically scale the number of throughput units (TUs) based on traffic.
- Partition count: For Standard tier, you can specify the number of partitions. Partitions enable parallel processing.
-
Tags (Optional): Add tags to your namespace for organization and resource management.
-
Review + create: Click the "Review + create" button to validate your configuration.
-
Create: After validation passes, click the "Create" button to deploy your Event Hubs namespace.
Accessing Your Namespace
Once the namespace is deployed, you can navigate to it in the Azure portal. From the namespace overview page, you can:
- Access connection strings: Go to "Shared access policies" to get the connection strings needed to connect your applications to Event Hubs.
- Create Event Hubs: Click "+ Event Hub" to create your first event hub within this namespace.
- Monitor metrics: View performance and usage metrics for your namespace.
Congratulations! You have successfully created an Azure Event Hubs namespace. The next step is to create an Event Hub within this namespace to start sending and receiving events.
Continue to the next section to learn how to create an Event Hub within your new namespace.
Next: Creating Event Hubs