Data Source: azurermEventhub
Use this data source to access information about an existing EventHub.
Example Usage
import * as cdktf from "cdktf";
/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as azurerm from "./.gen/providers/azurerm";
/*The following providers are missing schema information and might need manual adjustments to synthesize correctly: azurerm.
For a more precise conversion please use the --provider flag in convert.*/
const dataAzurermEventhubExample =
new azurerm.dataAzurermEventhub.DataAzurermEventhub(this, "example", {
name: "search-eventhub",
namespace_name: "search-eventhubns",
resource_group_name: "search-service",
});
new cdktf.TerraformOutput(this, "eventhub_id", {
value: dataAzurermEventhubExample.id,
});
Arguments Reference
The following arguments are supported:
-
name
- (Required) The name of this EventHub. -
resourceGroupName
- (Required) The name of the Resource Group where the EventHub exists. -
namespaceName
- (Required) The name of the EventHub Namespace where the EventHub exists.
Attributes Reference
In addition to the Arguments listed above - the following Attributes are exported:
-
id
- The ID of the EventHub. -
partitionCount
- The number of partitions in the EventHub. -
partitionIds
- The identifiers for the partitions of this EventHub.
Timeouts
The timeouts
block allows you to specify timeouts for certain actions:
read
- (Defaults to 5 minutes) Used when retrieving the EventHub.