get Topic
Use this data source to access information about an existing Service Bus Topic.
Example Usage
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azure.servicebus.ServicebusFunctions;
import com.pulumi.azure.servicebus.inputs.GetTopicArgs;
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 example = ServicebusFunctions.getTopic(GetTopicArgs.builder()
.name("existing")
.namespaceId("existing")
.build());
ctx.export("id", example.applyValue(getTopicResult -> getTopicResult.id()));
}
}
Content copied to clipboard
Return
A collection of values returned by getTopic.
Parameters
argument
A collection of arguments for invoking getTopic.
suspend fun getTopic(name: String, namespaceId: String? = null, namespaceName: String? = null, resourceGroupName: String? = null): GetTopicResult
Return
A collection of values returned by getTopic.
See also
Parameters
name
The name of this Service Bus Topic.
namespace Id
The ID of the ServiceBus Namespace where the Service Bus Topic exists.
namespace Name
The name of the Service Bus Namespace.
resource Group Name
The name of the Resource Group where the Service Bus Topic exists.
Note:
namespace_name
andresource_group_name
has been deprecated and will be removed in version 4.0 of the provider in favour ofnamespace_id
.
Return
A collection of values returned by getTopic.
See also
Parameters
argument
Builder for com.pulumi.azure.servicebus.kotlin.inputs.GetTopicPlainArgs.