1. Packages
  2. Azure Classic
  3. API Docs
  4. eventhub
  5. EventHub

We recommend using Azure Native.

Azure Classic v5.72.0 published on Monday, Apr 15, 2024 by Pulumi

azure.eventhub.EventHub

Explore with Pulumi AI

azure logo

We recommend using Azure Native.

Azure Classic v5.72.0 published on Monday, Apr 15, 2024 by Pulumi

    Manages a Event Hubs as a nested resource within a Event Hubs namespace.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as azure from "@pulumi/azure";
    
    const example = new azure.core.ResourceGroup("example", {
        name: "example-resources",
        location: "West Europe",
    });
    const exampleEventHubNamespace = new azure.eventhub.EventHubNamespace("example", {
        name: "acceptanceTestEventHubNamespace",
        location: example.location,
        resourceGroupName: example.name,
        sku: "Standard",
        capacity: 1,
        tags: {
            environment: "Production",
        },
    });
    const exampleEventHub = new azure.eventhub.EventHub("example", {
        name: "acceptanceTestEventHub",
        namespaceName: exampleEventHubNamespace.name,
        resourceGroupName: example.name,
        partitionCount: 2,
        messageRetention: 1,
    });
    
    import pulumi
    import pulumi_azure as azure
    
    example = azure.core.ResourceGroup("example",
        name="example-resources",
        location="West Europe")
    example_event_hub_namespace = azure.eventhub.EventHubNamespace("example",
        name="acceptanceTestEventHubNamespace",
        location=example.location,
        resource_group_name=example.name,
        sku="Standard",
        capacity=1,
        tags={
            "environment": "Production",
        })
    example_event_hub = azure.eventhub.EventHub("example",
        name="acceptanceTestEventHub",
        namespace_name=example_event_hub_namespace.name,
        resource_group_name=example.name,
        partition_count=2,
        message_retention=1)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
    	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/eventhub"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
    			Name:     pulumi.String("example-resources"),
    			Location: pulumi.String("West Europe"),
    		})
    		if err != nil {
    			return err
    		}
    		exampleEventHubNamespace, err := eventhub.NewEventHubNamespace(ctx, "example", &eventhub.EventHubNamespaceArgs{
    			Name:              pulumi.String("acceptanceTestEventHubNamespace"),
    			Location:          example.Location,
    			ResourceGroupName: example.Name,
    			Sku:               pulumi.String("Standard"),
    			Capacity:          pulumi.Int(1),
    			Tags: pulumi.StringMap{
    				"environment": pulumi.String("Production"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = eventhub.NewEventHub(ctx, "example", &eventhub.EventHubArgs{
    			Name:              pulumi.String("acceptanceTestEventHub"),
    			NamespaceName:     exampleEventHubNamespace.Name,
    			ResourceGroupName: example.Name,
    			PartitionCount:    pulumi.Int(2),
    			MessageRetention:  pulumi.Int(1),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Azure = Pulumi.Azure;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Azure.Core.ResourceGroup("example", new()
        {
            Name = "example-resources",
            Location = "West Europe",
        });
    
        var exampleEventHubNamespace = new Azure.EventHub.EventHubNamespace("example", new()
        {
            Name = "acceptanceTestEventHubNamespace",
            Location = example.Location,
            ResourceGroupName = example.Name,
            Sku = "Standard",
            Capacity = 1,
            Tags = 
            {
                { "environment", "Production" },
            },
        });
    
        var exampleEventHub = new Azure.EventHub.EventHub("example", new()
        {
            Name = "acceptanceTestEventHub",
            NamespaceName = exampleEventHubNamespace.Name,
            ResourceGroupName = example.Name,
            PartitionCount = 2,
            MessageRetention = 1,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azure.core.ResourceGroup;
    import com.pulumi.azure.core.ResourceGroupArgs;
    import com.pulumi.azure.eventhub.EventHubNamespace;
    import com.pulumi.azure.eventhub.EventHubNamespaceArgs;
    import com.pulumi.azure.eventhub.EventHub;
    import com.pulumi.azure.eventhub.EventHubArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new ResourceGroup("example", ResourceGroupArgs.builder()        
                .name("example-resources")
                .location("West Europe")
                .build());
    
            var exampleEventHubNamespace = new EventHubNamespace("exampleEventHubNamespace", EventHubNamespaceArgs.builder()        
                .name("acceptanceTestEventHubNamespace")
                .location(example.location())
                .resourceGroupName(example.name())
                .sku("Standard")
                .capacity(1)
                .tags(Map.of("environment", "Production"))
                .build());
    
            var exampleEventHub = new EventHub("exampleEventHub", EventHubArgs.builder()        
                .name("acceptanceTestEventHub")
                .namespaceName(exampleEventHubNamespace.name())
                .resourceGroupName(example.name())
                .partitionCount(2)
                .messageRetention(1)
                .build());
    
        }
    }
    
    resources:
      example:
        type: azure:core:ResourceGroup
        properties:
          name: example-resources
          location: West Europe
      exampleEventHubNamespace:
        type: azure:eventhub:EventHubNamespace
        name: example
        properties:
          name: acceptanceTestEventHubNamespace
          location: ${example.location}
          resourceGroupName: ${example.name}
          sku: Standard
          capacity: 1
          tags:
            environment: Production
      exampleEventHub:
        type: azure:eventhub:EventHub
        name: example
        properties:
          name: acceptanceTestEventHub
          namespaceName: ${exampleEventHubNamespace.name}
          resourceGroupName: ${example.name}
          partitionCount: 2
          messageRetention: 1
    

    Create EventHub Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new EventHub(name: string, args: EventHubArgs, opts?: CustomResourceOptions);
    @overload
    def EventHub(resource_name: str,
                 args: EventHubArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def EventHub(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 message_retention: Optional[int] = None,
                 namespace_name: Optional[str] = None,
                 partition_count: Optional[int] = None,
                 resource_group_name: Optional[str] = None,
                 capture_description: Optional[EventHubCaptureDescriptionArgs] = None,
                 name: Optional[str] = None,
                 status: Optional[str] = None)
    func NewEventHub(ctx *Context, name string, args EventHubArgs, opts ...ResourceOption) (*EventHub, error)
    public EventHub(string name, EventHubArgs args, CustomResourceOptions? opts = null)
    public EventHub(String name, EventHubArgs args)
    public EventHub(String name, EventHubArgs args, CustomResourceOptions options)
    
    type: azure:eventhub:EventHub
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args EventHubArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args EventHubArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args EventHubArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args EventHubArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args EventHubArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var eventHubResource = new Azure.EventHub.EventHub("eventHubResource", new()
    {
        MessageRetention = 0,
        NamespaceName = "string",
        PartitionCount = 0,
        ResourceGroupName = "string",
        CaptureDescription = new Azure.EventHub.Inputs.EventHubCaptureDescriptionArgs
        {
            Destination = new Azure.EventHub.Inputs.EventHubCaptureDescriptionDestinationArgs
            {
                ArchiveNameFormat = "string",
                BlobContainerName = "string",
                Name = "string",
                StorageAccountId = "string",
            },
            Enabled = false,
            Encoding = "string",
            IntervalInSeconds = 0,
            SizeLimitInBytes = 0,
            SkipEmptyArchives = false,
        },
        Name = "string",
        Status = "string",
    });
    
    example, err := eventhub.NewEventHub(ctx, "eventHubResource", &eventhub.EventHubArgs{
    	MessageRetention:  pulumi.Int(0),
    	NamespaceName:     pulumi.String("string"),
    	PartitionCount:    pulumi.Int(0),
    	ResourceGroupName: pulumi.String("string"),
    	CaptureDescription: &eventhub.EventHubCaptureDescriptionArgs{
    		Destination: &eventhub.EventHubCaptureDescriptionDestinationArgs{
    			ArchiveNameFormat: pulumi.String("string"),
    			BlobContainerName: pulumi.String("string"),
    			Name:              pulumi.String("string"),
    			StorageAccountId:  pulumi.String("string"),
    		},
    		Enabled:           pulumi.Bool(false),
    		Encoding:          pulumi.String("string"),
    		IntervalInSeconds: pulumi.Int(0),
    		SizeLimitInBytes:  pulumi.Int(0),
    		SkipEmptyArchives: pulumi.Bool(false),
    	},
    	Name:   pulumi.String("string"),
    	Status: pulumi.String("string"),
    })
    
    var eventHubResource = new EventHub("eventHubResource", EventHubArgs.builder()        
        .messageRetention(0)
        .namespaceName("string")
        .partitionCount(0)
        .resourceGroupName("string")
        .captureDescription(EventHubCaptureDescriptionArgs.builder()
            .destination(EventHubCaptureDescriptionDestinationArgs.builder()
                .archiveNameFormat("string")
                .blobContainerName("string")
                .name("string")
                .storageAccountId("string")
                .build())
            .enabled(false)
            .encoding("string")
            .intervalInSeconds(0)
            .sizeLimitInBytes(0)
            .skipEmptyArchives(false)
            .build())
        .name("string")
        .status("string")
        .build());
    
    event_hub_resource = azure.eventhub.EventHub("eventHubResource",
        message_retention=0,
        namespace_name="string",
        partition_count=0,
        resource_group_name="string",
        capture_description=azure.eventhub.EventHubCaptureDescriptionArgs(
            destination=azure.eventhub.EventHubCaptureDescriptionDestinationArgs(
                archive_name_format="string",
                blob_container_name="string",
                name="string",
                storage_account_id="string",
            ),
            enabled=False,
            encoding="string",
            interval_in_seconds=0,
            size_limit_in_bytes=0,
            skip_empty_archives=False,
        ),
        name="string",
        status="string")
    
    const eventHubResource = new azure.eventhub.EventHub("eventHubResource", {
        messageRetention: 0,
        namespaceName: "string",
        partitionCount: 0,
        resourceGroupName: "string",
        captureDescription: {
            destination: {
                archiveNameFormat: "string",
                blobContainerName: "string",
                name: "string",
                storageAccountId: "string",
            },
            enabled: false,
            encoding: "string",
            intervalInSeconds: 0,
            sizeLimitInBytes: 0,
            skipEmptyArchives: false,
        },
        name: "string",
        status: "string",
    });
    
    type: azure:eventhub:EventHub
    properties:
        captureDescription:
            destination:
                archiveNameFormat: string
                blobContainerName: string
                name: string
                storageAccountId: string
            enabled: false
            encoding: string
            intervalInSeconds: 0
            sizeLimitInBytes: 0
            skipEmptyArchives: false
        messageRetention: 0
        name: string
        namespaceName: string
        partitionCount: 0
        resourceGroupName: string
        status: string
    

    EventHub Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The EventHub resource accepts the following input properties:

    MessageRetention int

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    NamespaceName string
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    PartitionCount int

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    ResourceGroupName string
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    CaptureDescription EventHubCaptureDescription
    A capture_description block as defined below.
    Name string
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    Status string
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    MessageRetention int

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    NamespaceName string
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    PartitionCount int

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    ResourceGroupName string
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    CaptureDescription EventHubCaptureDescriptionArgs
    A capture_description block as defined below.
    Name string
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    Status string
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    messageRetention Integer

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    namespaceName String
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    partitionCount Integer

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    resourceGroupName String
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    captureDescription EventHubCaptureDescription
    A capture_description block as defined below.
    name String
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    status String
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    messageRetention number

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    namespaceName string
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    partitionCount number

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    resourceGroupName string
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    captureDescription EventHubCaptureDescription
    A capture_description block as defined below.
    name string
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    status string
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    message_retention int

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    namespace_name str
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    partition_count int

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    resource_group_name str
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    capture_description EventHubCaptureDescriptionArgs
    A capture_description block as defined below.
    name str
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    status str
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    messageRetention Number

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    namespaceName String
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    partitionCount Number

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    resourceGroupName String
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    captureDescription Property Map
    A capture_description block as defined below.
    name String
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    status String
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the EventHub resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    PartitionIds List<string>
    The identifiers for partitions created for Event Hubs.
    Id string
    The provider-assigned unique ID for this managed resource.
    PartitionIds []string
    The identifiers for partitions created for Event Hubs.
    id String
    The provider-assigned unique ID for this managed resource.
    partitionIds List<String>
    The identifiers for partitions created for Event Hubs.
    id string
    The provider-assigned unique ID for this managed resource.
    partitionIds string[]
    The identifiers for partitions created for Event Hubs.
    id str
    The provider-assigned unique ID for this managed resource.
    partition_ids Sequence[str]
    The identifiers for partitions created for Event Hubs.
    id String
    The provider-assigned unique ID for this managed resource.
    partitionIds List<String>
    The identifiers for partitions created for Event Hubs.

    Look up Existing EventHub Resource

    Get an existing EventHub resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: EventHubState, opts?: CustomResourceOptions): EventHub
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            capture_description: Optional[EventHubCaptureDescriptionArgs] = None,
            message_retention: Optional[int] = None,
            name: Optional[str] = None,
            namespace_name: Optional[str] = None,
            partition_count: Optional[int] = None,
            partition_ids: Optional[Sequence[str]] = None,
            resource_group_name: Optional[str] = None,
            status: Optional[str] = None) -> EventHub
    func GetEventHub(ctx *Context, name string, id IDInput, state *EventHubState, opts ...ResourceOption) (*EventHub, error)
    public static EventHub Get(string name, Input<string> id, EventHubState? state, CustomResourceOptions? opts = null)
    public static EventHub get(String name, Output<String> id, EventHubState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    CaptureDescription EventHubCaptureDescription
    A capture_description block as defined below.
    MessageRetention int

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    Name string
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    NamespaceName string
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    PartitionCount int

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    PartitionIds List<string>
    The identifiers for partitions created for Event Hubs.
    ResourceGroupName string
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    Status string
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    CaptureDescription EventHubCaptureDescriptionArgs
    A capture_description block as defined below.
    MessageRetention int

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    Name string
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    NamespaceName string
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    PartitionCount int

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    PartitionIds []string
    The identifiers for partitions created for Event Hubs.
    ResourceGroupName string
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    Status string
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    captureDescription EventHubCaptureDescription
    A capture_description block as defined below.
    messageRetention Integer

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    name String
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    namespaceName String
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    partitionCount Integer

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    partitionIds List<String>
    The identifiers for partitions created for Event Hubs.
    resourceGroupName String
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    status String
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    captureDescription EventHubCaptureDescription
    A capture_description block as defined below.
    messageRetention number

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    name string
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    namespaceName string
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    partitionCount number

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    partitionIds string[]
    The identifiers for partitions created for Event Hubs.
    resourceGroupName string
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    status string
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    capture_description EventHubCaptureDescriptionArgs
    A capture_description block as defined below.
    message_retention int

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    name str
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    namespace_name str
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    partition_count int

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    partition_ids Sequence[str]
    The identifiers for partitions created for Event Hubs.
    resource_group_name str
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    status str
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.
    captureDescription Property Map
    A capture_description block as defined below.
    messageRetention Number

    Specifies the number of days to retain the events for this Event Hub.

    Note: When using a dedicated Event Hubs cluster, maximum value of message_retention is 90 days. When using a shared parent EventHub Namespace, maximum value is 7 days; or 1 day when using a Basic SKU for the shared parent EventHub Namespace.

    name String
    Specifies the name of the EventHub resource. Changing this forces a new resource to be created.
    namespaceName String
    Specifies the name of the EventHub Namespace. Changing this forces a new resource to be created.
    partitionCount Number

    Specifies the current number of shards on the Event Hub.

    Note: partition_count cannot be changed unless Eventhub Namespace SKU is Premium and cannot be decreased.

    Note: When using a dedicated Event Hubs cluster, maximum value of partition_count is 1024. When using a shared parent EventHub Namespace, maximum value is 32.

    partitionIds List<String>
    The identifiers for partitions created for Event Hubs.
    resourceGroupName String
    The name of the resource group in which the EventHub's parent Namespace exists. Changing this forces a new resource to be created.
    status String
    Specifies the status of the Event Hub resource. Possible values are Active, Disabled and SendDisabled. Defaults to Active.

    Supporting Types

    EventHubCaptureDescription, EventHubCaptureDescriptionArgs

    Destination EventHubCaptureDescriptionDestination
    A destination block as defined below.
    Enabled bool
    Specifies if the Capture Description is Enabled.
    Encoding string
    Specifies the Encoding used for the Capture Description. Possible values are Avro and AvroDeflate.
    IntervalInSeconds int
    Specifies the time interval in seconds at which the capture will happen. Values can be between 60 and 900 seconds. Defaults to 300 seconds.
    SizeLimitInBytes int
    Specifies the amount of data built up in your EventHub before a Capture Operation occurs. Value should be between 10485760 and 524288000 bytes. Defaults to 314572800 bytes.
    SkipEmptyArchives bool
    Specifies if empty files should not be emitted if no events occur during the Capture time window. Defaults to false.
    Destination EventHubCaptureDescriptionDestination
    A destination block as defined below.
    Enabled bool
    Specifies if the Capture Description is Enabled.
    Encoding string
    Specifies the Encoding used for the Capture Description. Possible values are Avro and AvroDeflate.
    IntervalInSeconds int
    Specifies the time interval in seconds at which the capture will happen. Values can be between 60 and 900 seconds. Defaults to 300 seconds.
    SizeLimitInBytes int
    Specifies the amount of data built up in your EventHub before a Capture Operation occurs. Value should be between 10485760 and 524288000 bytes. Defaults to 314572800 bytes.
    SkipEmptyArchives bool
    Specifies if empty files should not be emitted if no events occur during the Capture time window. Defaults to false.
    destination EventHubCaptureDescriptionDestination
    A destination block as defined below.
    enabled Boolean
    Specifies if the Capture Description is Enabled.
    encoding String
    Specifies the Encoding used for the Capture Description. Possible values are Avro and AvroDeflate.
    intervalInSeconds Integer
    Specifies the time interval in seconds at which the capture will happen. Values can be between 60 and 900 seconds. Defaults to 300 seconds.
    sizeLimitInBytes Integer
    Specifies the amount of data built up in your EventHub before a Capture Operation occurs. Value should be between 10485760 and 524288000 bytes. Defaults to 314572800 bytes.
    skipEmptyArchives Boolean
    Specifies if empty files should not be emitted if no events occur during the Capture time window. Defaults to false.
    destination EventHubCaptureDescriptionDestination
    A destination block as defined below.
    enabled boolean
    Specifies if the Capture Description is Enabled.
    encoding string
    Specifies the Encoding used for the Capture Description. Possible values are Avro and AvroDeflate.
    intervalInSeconds number
    Specifies the time interval in seconds at which the capture will happen. Values can be between 60 and 900 seconds. Defaults to 300 seconds.
    sizeLimitInBytes number
    Specifies the amount of data built up in your EventHub before a Capture Operation occurs. Value should be between 10485760 and 524288000 bytes. Defaults to 314572800 bytes.
    skipEmptyArchives boolean
    Specifies if empty files should not be emitted if no events occur during the Capture time window. Defaults to false.
    destination EventHubCaptureDescriptionDestination
    A destination block as defined below.
    enabled bool
    Specifies if the Capture Description is Enabled.
    encoding str
    Specifies the Encoding used for the Capture Description. Possible values are Avro and AvroDeflate.
    interval_in_seconds int
    Specifies the time interval in seconds at which the capture will happen. Values can be between 60 and 900 seconds. Defaults to 300 seconds.
    size_limit_in_bytes int
    Specifies the amount of data built up in your EventHub before a Capture Operation occurs. Value should be between 10485760 and 524288000 bytes. Defaults to 314572800 bytes.
    skip_empty_archives bool
    Specifies if empty files should not be emitted if no events occur during the Capture time window. Defaults to false.
    destination Property Map
    A destination block as defined below.
    enabled Boolean
    Specifies if the Capture Description is Enabled.
    encoding String
    Specifies the Encoding used for the Capture Description. Possible values are Avro and AvroDeflate.
    intervalInSeconds Number
    Specifies the time interval in seconds at which the capture will happen. Values can be between 60 and 900 seconds. Defaults to 300 seconds.
    sizeLimitInBytes Number
    Specifies the amount of data built up in your EventHub before a Capture Operation occurs. Value should be between 10485760 and 524288000 bytes. Defaults to 314572800 bytes.
    skipEmptyArchives Boolean
    Specifies if empty files should not be emitted if no events occur during the Capture time window. Defaults to false.

    EventHubCaptureDescriptionDestination, EventHubCaptureDescriptionDestinationArgs

    ArchiveNameFormat string
    The Blob naming convention for archiving. e.g. {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}. Here all the parameters (Namespace,EventHub .. etc) are mandatory irrespective of order
    BlobContainerName string
    The name of the Container within the Blob Storage Account where messages should be archived.
    Name string

    The Name of the Destination where the capture should take place. At this time the only supported value is EventHubArchive.AzureBlockBlob.

    At this time it's only possible to Capture EventHub messages to Blob Storage. There's a Feature Request for the Azure SDK to add support for Capturing messages to Azure Data Lake here.

    StorageAccountId string
    The ID of the Blob Storage Account where messages should be archived.
    ArchiveNameFormat string
    The Blob naming convention for archiving. e.g. {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}. Here all the parameters (Namespace,EventHub .. etc) are mandatory irrespective of order
    BlobContainerName string
    The name of the Container within the Blob Storage Account where messages should be archived.
    Name string

    The Name of the Destination where the capture should take place. At this time the only supported value is EventHubArchive.AzureBlockBlob.

    At this time it's only possible to Capture EventHub messages to Blob Storage. There's a Feature Request for the Azure SDK to add support for Capturing messages to Azure Data Lake here.

    StorageAccountId string
    The ID of the Blob Storage Account where messages should be archived.
    archiveNameFormat String
    The Blob naming convention for archiving. e.g. {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}. Here all the parameters (Namespace,EventHub .. etc) are mandatory irrespective of order
    blobContainerName String
    The name of the Container within the Blob Storage Account where messages should be archived.
    name String

    The Name of the Destination where the capture should take place. At this time the only supported value is EventHubArchive.AzureBlockBlob.

    At this time it's only possible to Capture EventHub messages to Blob Storage. There's a Feature Request for the Azure SDK to add support for Capturing messages to Azure Data Lake here.

    storageAccountId String
    The ID of the Blob Storage Account where messages should be archived.
    archiveNameFormat string
    The Blob naming convention for archiving. e.g. {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}. Here all the parameters (Namespace,EventHub .. etc) are mandatory irrespective of order
    blobContainerName string
    The name of the Container within the Blob Storage Account where messages should be archived.
    name string

    The Name of the Destination where the capture should take place. At this time the only supported value is EventHubArchive.AzureBlockBlob.

    At this time it's only possible to Capture EventHub messages to Blob Storage. There's a Feature Request for the Azure SDK to add support for Capturing messages to Azure Data Lake here.

    storageAccountId string
    The ID of the Blob Storage Account where messages should be archived.
    archive_name_format str
    The Blob naming convention for archiving. e.g. {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}. Here all the parameters (Namespace,EventHub .. etc) are mandatory irrespective of order
    blob_container_name str
    The name of the Container within the Blob Storage Account where messages should be archived.
    name str

    The Name of the Destination where the capture should take place. At this time the only supported value is EventHubArchive.AzureBlockBlob.

    At this time it's only possible to Capture EventHub messages to Blob Storage. There's a Feature Request for the Azure SDK to add support for Capturing messages to Azure Data Lake here.

    storage_account_id str
    The ID of the Blob Storage Account where messages should be archived.
    archiveNameFormat String
    The Blob naming convention for archiving. e.g. {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}. Here all the parameters (Namespace,EventHub .. etc) are mandatory irrespective of order
    blobContainerName String
    The name of the Container within the Blob Storage Account where messages should be archived.
    name String

    The Name of the Destination where the capture should take place. At this time the only supported value is EventHubArchive.AzureBlockBlob.

    At this time it's only possible to Capture EventHub messages to Blob Storage. There's a Feature Request for the Azure SDK to add support for Capturing messages to Azure Data Lake here.

    storageAccountId String
    The ID of the Blob Storage Account where messages should be archived.

    Import

    EventHubs can be imported using the resource id, e.g.

    $ pulumi import azure:eventhub/eventHub:EventHub eventhub1 /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.EventHub/namespaces/namespace1/eventhubs/eventhub1
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Azure Classic pulumi/pulumi-azure
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the azurerm Terraform Provider.
    azure logo

    We recommend using Azure Native.

    Azure Classic v5.72.0 published on Monday, Apr 15, 2024 by Pulumi