Namespace
Manages a ServiceBus Namespace.
Example Usage
using Pulumi;
using Azure = Pulumi.Azure;
class MyStack : Stack
{
public MyStack()
{
var exampleResourceGroup = new Azure.Core.ResourceGroup("exampleResourceGroup", new Azure.Core.ResourceGroupArgs
{
Location = "West Europe",
});
var exampleNamespace = new Azure.ServiceBus.Namespace("exampleNamespace", new Azure.ServiceBus.NamespaceArgs
{
Location = exampleResourceGroup.Location,
ResourceGroupName = exampleResourceGroup.Name,
Sku = "Standard",
Tags =
{
{ "source", "example" },
},
});
}
}
package main
import (
"github.com/pulumi/pulumi-azure/sdk/v3/go/azure/core"
"github.com/pulumi/pulumi-azure/sdk/v3/go/azure/servicebus"
"github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
exampleResourceGroup, err := core.NewResourceGroup(ctx, "exampleResourceGroup", &core.ResourceGroupArgs{
Location: pulumi.String("West Europe"),
})
if err != nil {
return err
}
_, err = servicebus.NewNamespace(ctx, "exampleNamespace", &servicebus.NamespaceArgs{
Location: exampleResourceGroup.Location,
ResourceGroupName: exampleResourceGroup.Name,
Sku: pulumi.String("Standard"),
Tags: pulumi.Map{
"source": pulumi.String("example"),
},
})
if err != nil {
return err
}
return nil
})
}import pulumi
import pulumi_azure as azure
example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe")
example_namespace = azure.servicebus.Namespace("exampleNamespace",
location=example_resource_group.location,
resource_group_name=example_resource_group.name,
sku="Standard",
tags={
"source": "example",
})import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
const exampleResourceGroup = new azure.core.ResourceGroup("exampleResourceGroup", {location: "West Europe"});
const exampleNamespace = new azure.servicebus.Namespace("exampleNamespace", {
location: exampleResourceGroup.location,
resourceGroupName: exampleResourceGroup.name,
sku: "Standard",
tags: {
source: "example",
},
});Deprecated: azure.eventhub.Namespace has been deprecated in favor of azure.servicebus.Namespace
Create a Namespace Resource
new Namespace(name: string, args: NamespaceArgs, opts?: CustomResourceOptions);def Namespace(resource_name, opts=None, capacity=None, location=None, name=None, resource_group_name=None, sku=None, tags=None, zone_redundant=None, __props__=None);func NewNamespace(ctx *Context, name string, args NamespaceArgs, opts ...ResourceOption) (*Namespace, error)public Namespace(string name, NamespaceArgs args, CustomResourceOptions? opts = null)- name string
- The unique name of the resource.
- args NamespaceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- opts ResourceOptions
- A bag of options that control this resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args NamespaceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args NamespaceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
Namespace Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.
Inputs
The Namespace resource accepts the following input properties:
- Resource
Group stringName The name of the resource group in which to create the namespace.
- Sku string
Defines which tier to use. Options are basic, standard or premium. Changing this forces a new resource to be created.
- Capacity int
Specifies the capacity. When
skuisPremium, capacity can be1,2,4or8. WhenskuisBasicorStandard, capacity can be0only.- Location string
Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
- Name string
Specifies the name of the ServiceBus Namespace resource . Changing this forces a new resource to be created.
- Dictionary<string, string>
A mapping of tags to assign to the resource.
- Zone
Redundant bool Whether or not this resource is zone redundant.
skuneeds to bePremium. Defaults tofalse.
- Resource
Group stringName The name of the resource group in which to create the namespace.
- Sku string
Defines which tier to use. Options are basic, standard or premium. Changing this forces a new resource to be created.
- Capacity int
Specifies the capacity. When
skuisPremium, capacity can be1,2,4or8. WhenskuisBasicorStandard, capacity can be0only.- Location string
Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
- Name string
Specifies the name of the ServiceBus Namespace resource . Changing this forces a new resource to be created.
- map[string]string
A mapping of tags to assign to the resource.
- Zone
Redundant bool Whether or not this resource is zone redundant.
skuneeds to bePremium. Defaults tofalse.
- resource
Group stringName The name of the resource group in which to create the namespace.
- sku string
Defines which tier to use. Options are basic, standard or premium. Changing this forces a new resource to be created.
- capacity number
Specifies the capacity. When
skuisPremium, capacity can be1,2,4or8. WhenskuisBasicorStandard, capacity can be0only.- location string
Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
- name string
Specifies the name of the ServiceBus Namespace resource . Changing this forces a new resource to be created.
- {[key: string]: string}
A mapping of tags to assign to the resource.
- zone
Redundant boolean Whether or not this resource is zone redundant.
skuneeds to bePremium. Defaults tofalse.
- resource_
group_ strname The name of the resource group in which to create the namespace.
- sku str
Defines which tier to use. Options are basic, standard or premium. Changing this forces a new resource to be created.
- capacity float
Specifies the capacity. When
skuisPremium, capacity can be1,2,4or8. WhenskuisBasicorStandard, capacity can be0only.- location str
Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
- name str
Specifies the name of the ServiceBus Namespace resource . Changing this forces a new resource to be created.
- Dict[str, str]
A mapping of tags to assign to the resource.
- zone_
redundant bool Whether or not this resource is zone redundant.
skuneeds to bePremium. Defaults tofalse.
Outputs
All input properties are implicitly available as output properties. Additionally, the Namespace resource produces the following output properties:
- Default
Primary stringConnection String The primary connection string for the authorization rule
RootManageSharedAccessKey.- Default
Primary stringKey The primary access key for the authorization rule
RootManageSharedAccessKey.- Default
Secondary stringConnection String The secondary connection string for the authorization rule
RootManageSharedAccessKey.- Default
Secondary stringKey The secondary access key for the authorization rule
RootManageSharedAccessKey.- Id string
- The provider-assigned unique ID for this managed resource.
- Default
Primary stringConnection String The primary connection string for the authorization rule
RootManageSharedAccessKey.- Default
Primary stringKey The primary access key for the authorization rule
RootManageSharedAccessKey.- Default
Secondary stringConnection String The secondary connection string for the authorization rule
RootManageSharedAccessKey.- Default
Secondary stringKey The secondary access key for the authorization rule
RootManageSharedAccessKey.- Id string
- The provider-assigned unique ID for this managed resource.
- default
Primary stringConnection String The primary connection string for the authorization rule
RootManageSharedAccessKey.- default
Primary stringKey The primary access key for the authorization rule
RootManageSharedAccessKey.- default
Secondary stringConnection String The secondary connection string for the authorization rule
RootManageSharedAccessKey.- default
Secondary stringKey The secondary access key for the authorization rule
RootManageSharedAccessKey.- id string
- The provider-assigned unique ID for this managed resource.
- default_
primary_ strconnection_ string The primary connection string for the authorization rule
RootManageSharedAccessKey.- default_
primary_ strkey The primary access key for the authorization rule
RootManageSharedAccessKey.- default_
secondary_ strconnection_ string The secondary connection string for the authorization rule
RootManageSharedAccessKey.- default_
secondary_ strkey The secondary access key for the authorization rule
RootManageSharedAccessKey.- id str
- The provider-assigned unique ID for this managed resource.
Look up an Existing Namespace Resource
Get an existing Namespace 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?: NamespaceState, opts?: CustomResourceOptions): Namespacestatic get(resource_name, id, opts=None, capacity=None, default_primary_connection_string=None, default_primary_key=None, default_secondary_connection_string=None, default_secondary_key=None, location=None, name=None, resource_group_name=None, sku=None, tags=None, zone_redundant=None, __props__=None);func GetNamespace(ctx *Context, name string, id IDInput, state *NamespaceState, opts ...ResourceOption) (*Namespace, error)public static Namespace Get(string name, Input<string> id, NamespaceState? state, CustomResourceOptions? opts = null)- 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.
The following state arguments are supported:
- Capacity int
Specifies the capacity. When
skuisPremium, capacity can be1,2,4or8. WhenskuisBasicorStandard, capacity can be0only.- Default
Primary stringConnection String The primary connection string for the authorization rule
RootManageSharedAccessKey.- Default
Primary stringKey The primary access key for the authorization rule
RootManageSharedAccessKey.- Default
Secondary stringConnection String The secondary connection string for the authorization rule
RootManageSharedAccessKey.- Default
Secondary stringKey The secondary access key for the authorization rule
RootManageSharedAccessKey.- Location string
Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
- Name string
Specifies the name of the ServiceBus Namespace resource . Changing this forces a new resource to be created.
- Resource
Group stringName The name of the resource group in which to create the namespace.
- Sku string
Defines which tier to use. Options are basic, standard or premium. Changing this forces a new resource to be created.
- Dictionary<string, string>
A mapping of tags to assign to the resource.
- Zone
Redundant bool Whether or not this resource is zone redundant.
skuneeds to bePremium. Defaults tofalse.
- Capacity int
Specifies the capacity. When
skuisPremium, capacity can be1,2,4or8. WhenskuisBasicorStandard, capacity can be0only.- Default
Primary stringConnection String The primary connection string for the authorization rule
RootManageSharedAccessKey.- Default
Primary stringKey The primary access key for the authorization rule
RootManageSharedAccessKey.- Default
Secondary stringConnection String The secondary connection string for the authorization rule
RootManageSharedAccessKey.- Default
Secondary stringKey The secondary access key for the authorization rule
RootManageSharedAccessKey.- Location string
Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
- Name string
Specifies the name of the ServiceBus Namespace resource . Changing this forces a new resource to be created.
- Resource
Group stringName The name of the resource group in which to create the namespace.
- Sku string
Defines which tier to use. Options are basic, standard or premium. Changing this forces a new resource to be created.
- map[string]string
A mapping of tags to assign to the resource.
- Zone
Redundant bool Whether or not this resource is zone redundant.
skuneeds to bePremium. Defaults tofalse.
- capacity number
Specifies the capacity. When
skuisPremium, capacity can be1,2,4or8. WhenskuisBasicorStandard, capacity can be0only.- default
Primary stringConnection String The primary connection string for the authorization rule
RootManageSharedAccessKey.- default
Primary stringKey The primary access key for the authorization rule
RootManageSharedAccessKey.- default
Secondary stringConnection String The secondary connection string for the authorization rule
RootManageSharedAccessKey.- default
Secondary stringKey The secondary access key for the authorization rule
RootManageSharedAccessKey.- location string
Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
- name string
Specifies the name of the ServiceBus Namespace resource . Changing this forces a new resource to be created.
- resource
Group stringName The name of the resource group in which to create the namespace.
- sku string
Defines which tier to use. Options are basic, standard or premium. Changing this forces a new resource to be created.
- {[key: string]: string}
A mapping of tags to assign to the resource.
- zone
Redundant boolean Whether or not this resource is zone redundant.
skuneeds to bePremium. Defaults tofalse.
- capacity float
Specifies the capacity. When
skuisPremium, capacity can be1,2,4or8. WhenskuisBasicorStandard, capacity can be0only.- default_
primary_ strconnection_ string The primary connection string for the authorization rule
RootManageSharedAccessKey.- default_
primary_ strkey The primary access key for the authorization rule
RootManageSharedAccessKey.- default_
secondary_ strconnection_ string The secondary connection string for the authorization rule
RootManageSharedAccessKey.- default_
secondary_ strkey The secondary access key for the authorization rule
RootManageSharedAccessKey.- location str
Specifies the supported Azure location where the resource exists. Changing this forces a new resource to be created.
- name str
Specifies the name of the ServiceBus Namespace resource . Changing this forces a new resource to be created.
- resource_
group_ strname The name of the resource group in which to create the namespace.
- sku str
Defines which tier to use. Options are basic, standard or premium. Changing this forces a new resource to be created.
- Dict[str, str]
A mapping of tags to assign to the resource.
- zone_
redundant bool Whether or not this resource is zone redundant.
skuneeds to bePremium. Defaults tofalse.
Package Details
- Repository
- https://github.com/pulumi/pulumi-azure
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azurermTerraform Provider.