We recommend using Azure Native.
Azure v6.10.0 published on Tuesday, Nov 19, 2024 by Pulumi
azure.eventhub.getConsumeGroup
Explore with Pulumi AI
Use this data source to access information about an existing Event Hubs Consumer Group within an Event Hub.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const test = azure.eventhub.getConsumeGroup({
name: testAzurermEventhubConsumerGroup.name,
namespaceName: testAzurermEventhubNamespace.name,
eventhubName: testAzurermEventhub.name,
resourceGroupName: testAzurermResourceGroup.name,
});
import pulumi
import pulumi_azure as azure
test = azure.eventhub.get_consume_group(name=test_azurerm_eventhub_consumer_group["name"],
namespace_name=test_azurerm_eventhub_namespace["name"],
eventhub_name=test_azurerm_eventhub["name"],
resource_group_name=test_azurerm_resource_group["name"])
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v6/go/azure/eventhub"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := eventhub.GetConsumeGroup(ctx, &eventhub.GetConsumeGroupArgs{
Name: testAzurermEventhubConsumerGroup.Name,
NamespaceName: testAzurermEventhubNamespace.Name,
EventhubName: testAzurermEventhub.Name,
ResourceGroupName: testAzurermResourceGroup.Name,
}, nil)
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 test = Azure.EventHub.GetConsumeGroup.Invoke(new()
{
Name = testAzurermEventhubConsumerGroup.Name,
NamespaceName = testAzurermEventhubNamespace.Name,
EventhubName = testAzurermEventhub.Name,
ResourceGroupName = testAzurermResourceGroup.Name,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.eventhub.EventhubFunctions;
import com.pulumi.azure.eventhub.inputs.GetConsumeGroupArgs;
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) {
final var test = EventhubFunctions.getConsumeGroup(GetConsumeGroupArgs.builder()
.name(testAzurermEventhubConsumerGroup.name())
.namespaceName(testAzurermEventhubNamespace.name())
.eventhubName(testAzurermEventhub.name())
.resourceGroupName(testAzurermResourceGroup.name())
.build());
}
}
variables:
test:
fn::invoke:
Function: azure:eventhub:getConsumeGroup
Arguments:
name: ${testAzurermEventhubConsumerGroup.name}
namespaceName: ${testAzurermEventhubNamespace.name}
eventhubName: ${testAzurermEventhub.name}
resourceGroupName: ${testAzurermResourceGroup.name}
Using getConsumeGroup
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getConsumeGroup(args: GetConsumeGroupArgs, opts?: InvokeOptions): Promise<GetConsumeGroupResult>
function getConsumeGroupOutput(args: GetConsumeGroupOutputArgs, opts?: InvokeOptions): Output<GetConsumeGroupResult>
def get_consume_group(eventhub_name: Optional[str] = None,
name: Optional[str] = None,
namespace_name: Optional[str] = None,
resource_group_name: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetConsumeGroupResult
def get_consume_group_output(eventhub_name: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
namespace_name: Optional[pulumi.Input[str]] = None,
resource_group_name: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetConsumeGroupResult]
func GetConsumeGroup(ctx *Context, args *GetConsumeGroupArgs, opts ...InvokeOption) (*GetConsumeGroupResult, error)
func GetConsumeGroupOutput(ctx *Context, args *GetConsumeGroupOutputArgs, opts ...InvokeOption) GetConsumeGroupResultOutput
> Note: This function is named GetConsumeGroup
in the Go SDK.
public static class GetConsumeGroup
{
public static Task<GetConsumeGroupResult> InvokeAsync(GetConsumeGroupArgs args, InvokeOptions? opts = null)
public static Output<GetConsumeGroupResult> Invoke(GetConsumeGroupInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetConsumeGroupResult> getConsumeGroup(GetConsumeGroupArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: azure:eventhub/getConsumeGroup:getConsumeGroup
arguments:
# arguments dictionary
The following arguments are supported:
- Eventhub
Name string - Specifies the name of the EventHub.
- Name string
- Specifies the name of the EventHub Consumer Group resource.
- Namespace
Name string - Specifies the name of the grandparent EventHub Namespace.
- Resource
Group stringName - The name of the resource group in which the EventHub Consumer Group's grandparent Namespace exists.
- Eventhub
Name string - Specifies the name of the EventHub.
- Name string
- Specifies the name of the EventHub Consumer Group resource.
- Namespace
Name string - Specifies the name of the grandparent EventHub Namespace.
- Resource
Group stringName - The name of the resource group in which the EventHub Consumer Group's grandparent Namespace exists.
- eventhub
Name String - Specifies the name of the EventHub.
- name String
- Specifies the name of the EventHub Consumer Group resource.
- namespace
Name String - Specifies the name of the grandparent EventHub Namespace.
- resource
Group StringName - The name of the resource group in which the EventHub Consumer Group's grandparent Namespace exists.
- eventhub
Name string - Specifies the name of the EventHub.
- name string
- Specifies the name of the EventHub Consumer Group resource.
- namespace
Name string - Specifies the name of the grandparent EventHub Namespace.
- resource
Group stringName - The name of the resource group in which the EventHub Consumer Group's grandparent Namespace exists.
- eventhub_
name str - Specifies the name of the EventHub.
- name str
- Specifies the name of the EventHub Consumer Group resource.
- namespace_
name str - Specifies the name of the grandparent EventHub Namespace.
- resource_
group_ strname - The name of the resource group in which the EventHub Consumer Group's grandparent Namespace exists.
- eventhub
Name String - Specifies the name of the EventHub.
- name String
- Specifies the name of the EventHub Consumer Group resource.
- namespace
Name String - Specifies the name of the grandparent EventHub Namespace.
- resource
Group StringName - The name of the resource group in which the EventHub Consumer Group's grandparent Namespace exists.
getConsumeGroup Result
The following output properties are available:
- Eventhub
Name string - Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Namespace
Name string - Resource
Group stringName - User
Metadata string - Specifies the user metadata.
- Eventhub
Name string - Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Namespace
Name string - Resource
Group stringName - User
Metadata string - Specifies the user metadata.
- eventhub
Name String - id String
- The provider-assigned unique ID for this managed resource.
- name String
- namespace
Name String - resource
Group StringName - user
Metadata String - Specifies the user metadata.
- eventhub
Name string - id string
- The provider-assigned unique ID for this managed resource.
- name string
- namespace
Name string - resource
Group stringName - user
Metadata string - Specifies the user metadata.
- eventhub_
name str - id str
- The provider-assigned unique ID for this managed resource.
- name str
- namespace_
name str - resource_
group_ strname - user_
metadata str - Specifies the user metadata.
- eventhub
Name String - id String
- The provider-assigned unique ID for this managed resource.
- name String
- namespace
Name String - resource
Group StringName - user
Metadata String - Specifies the user metadata.
Package Details
- Repository
- Azure Classic pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurerm
Terraform Provider.