Alibaba Cloud

Pulumi Official
Package maintained by Pulumi
v3.19.0 published on Friday, Mar 18, 2022 by Pulumi

getEnterpriseInstances

This data source provides a list of DMS Enterprise Instances in an Alibaba Cloud account according to the specified filters.

NOTE: Available in 1.88.0+

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var dmsEnterpriseInstancesDs = Output.Create(AliCloud.Dms.GetEnterpriseInstances.InvokeAsync(new AliCloud.Dms.GetEnterpriseInstancesArgs
        {
            EnvType = "test",
            InstanceType = "mysql",
            NameRegex = "tf_testAcc",
            NetType = "CLASSIC",
            OutputFile = "dms_enterprise_instances.json",
        }));
        this.FirstDatabaseInstanceId = dmsEnterpriseInstancesDs.Apply(dmsEnterpriseInstancesDs => dmsEnterpriseInstancesDs.Instances?[0]?.InstanceId);
    }

    [Output("firstDatabaseInstanceId")]
    public Output<string> FirstDatabaseInstanceId { get; set; }
}
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/dms"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		dmsEnterpriseInstancesDs, err := dms.GetEnterpriseInstances(ctx, &dms.GetEnterpriseInstancesArgs{
			EnvType:      pulumi.StringRef("test"),
			InstanceType: pulumi.StringRef("mysql"),
			NameRegex:    pulumi.StringRef("tf_testAcc"),
			NetType:      pulumi.StringRef("CLASSIC"),
			OutputFile:   pulumi.StringRef("dms_enterprise_instances.json"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("firstDatabaseInstanceId", dmsEnterpriseInstancesDs.Instances[0].InstanceId)
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_alicloud as alicloud

dms_enterprise_instances_ds = alicloud.dms.get_enterprise_instances(env_type="test",
    instance_type="mysql",
    name_regex="tf_testAcc",
    net_type="CLASSIC",
    output_file="dms_enterprise_instances.json")
pulumi.export("firstDatabaseInstanceId", dms_enterprise_instances_ds.instances[0].instance_id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

// Declare the data source
const dmsEnterpriseInstancesDs = pulumi.output(alicloud.dms.getEnterpriseInstances({
    envType: "test",
    instanceType: "mysql",
    nameRegex: "tf_testAcc",
    netType: "CLASSIC",
    outputFile: "dms_enterprise_instances.json",
}));

export const firstDatabaseInstanceId = dmsEnterpriseInstancesDs.instances[0].instanceId;

Coming soon!

Using getEnterpriseInstances

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 getEnterpriseInstances(args: GetEnterpriseInstancesArgs, opts?: InvokeOptions): Promise<GetEnterpriseInstancesResult>
function getEnterpriseInstancesOutput(args: GetEnterpriseInstancesOutputArgs, opts?: InvokeOptions): Output<GetEnterpriseInstancesResult>
def get_enterprise_instances(env_type: Optional[str] = None,
                             instance_alias_regex: Optional[str] = None,
                             instance_source: Optional[str] = None,
                             instance_type: Optional[str] = None,
                             name_regex: Optional[str] = None,
                             net_type: Optional[str] = None,
                             output_file: Optional[str] = None,
                             search_key: Optional[str] = None,
                             status: Optional[str] = None,
                             tid: Optional[int] = None,
                             opts: Optional[InvokeOptions] = None) -> GetEnterpriseInstancesResult
def get_enterprise_instances_output(env_type: Optional[pulumi.Input[str]] = None,
                             instance_alias_regex: Optional[pulumi.Input[str]] = None,
                             instance_source: Optional[pulumi.Input[str]] = None,
                             instance_type: Optional[pulumi.Input[str]] = None,
                             name_regex: Optional[pulumi.Input[str]] = None,
                             net_type: Optional[pulumi.Input[str]] = None,
                             output_file: Optional[pulumi.Input[str]] = None,
                             search_key: Optional[pulumi.Input[str]] = None,
                             status: Optional[pulumi.Input[str]] = None,
                             tid: Optional[pulumi.Input[int]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetEnterpriseInstancesResult]
func GetEnterpriseInstances(ctx *Context, args *GetEnterpriseInstancesArgs, opts ...InvokeOption) (*GetEnterpriseInstancesResult, error)
func GetEnterpriseInstancesOutput(ctx *Context, args *GetEnterpriseInstancesOutputArgs, opts ...InvokeOption) GetEnterpriseInstancesResultOutput

> Note: This function is named GetEnterpriseInstances in the Go SDK.

public static class GetEnterpriseInstances 
{
    public static Task<GetEnterpriseInstancesResult> InvokeAsync(GetEnterpriseInstancesArgs args, InvokeOptions? opts = null)
    public static Output<GetEnterpriseInstancesResult> Invoke(GetEnterpriseInstancesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetEnterpriseInstancesResult> getEnterpriseInstances(GetEnterpriseInstancesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: alicloud:dms/getEnterpriseInstances:getEnterpriseInstances
  Arguments:
    # Arguments dictionary

The following arguments are supported:

EnvType string

The type of the environment to which the database instance belongs.

InstanceAliasRegex string

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

InstanceSource string

The source of the database instance.

InstanceType string

The ID of the database instance.

NameRegex string

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

NetType string

The network type of the database instance. Valid values: CLASSIC and VPC. For more information about the valid values, see the description of the RegisterInstance operation.

OutputFile string
SearchKey string

The keyword used to query database instances.

Status string

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

Tid int

The ID of the tenant in Data Management (DMS) Enterprise.

EnvType string

The type of the environment to which the database instance belongs.

InstanceAliasRegex string

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

InstanceSource string

The source of the database instance.

InstanceType string

The ID of the database instance.

NameRegex string

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

NetType string

The network type of the database instance. Valid values: CLASSIC and VPC. For more information about the valid values, see the description of the RegisterInstance operation.

OutputFile string
SearchKey string

The keyword used to query database instances.

Status string

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

Tid int

The ID of the tenant in Data Management (DMS) Enterprise.

envType String

The type of the environment to which the database instance belongs.

instanceAliasRegex String

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

instanceSource String

The source of the database instance.

instanceType String

The ID of the database instance.

nameRegex String

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

netType String

The network type of the database instance. Valid values: CLASSIC and VPC. For more information about the valid values, see the description of the RegisterInstance operation.

outputFile String
searchKey String

The keyword used to query database instances.

status String

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

tid Integer

The ID of the tenant in Data Management (DMS) Enterprise.

envType string

The type of the environment to which the database instance belongs.

instanceAliasRegex string

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

instanceSource string

The source of the database instance.

instanceType string

The ID of the database instance.

nameRegex string

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

netType string

The network type of the database instance. Valid values: CLASSIC and VPC. For more information about the valid values, see the description of the RegisterInstance operation.

outputFile string
searchKey string

The keyword used to query database instances.

status string

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

tid number

The ID of the tenant in Data Management (DMS) Enterprise.

env_type str

The type of the environment to which the database instance belongs.

instance_alias_regex str

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

instance_source str

The source of the database instance.

instance_type str

The ID of the database instance.

name_regex str

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

net_type str

The network type of the database instance. Valid values: CLASSIC and VPC. For more information about the valid values, see the description of the RegisterInstance operation.

output_file str
search_key str

The keyword used to query database instances.

status str

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

tid int

The ID of the tenant in Data Management (DMS) Enterprise.

envType String

The type of the environment to which the database instance belongs.

instanceAliasRegex String

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

instanceSource String

The source of the database instance.

instanceType String

The ID of the database instance.

nameRegex String

A regex string to filter the results by the DMS Enterprise Instance instance_alias.

netType String

The network type of the database instance. Valid values: CLASSIC and VPC. For more information about the valid values, see the description of the RegisterInstance operation.

outputFile String
searchKey String

The keyword used to query database instances.

status String

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

tid Number

The ID of the tenant in Data Management (DMS) Enterprise.

getEnterpriseInstances Result

The following output properties are available:

Id string

The provider-assigned unique ID for this managed resource.

Ids List<string>

A list of DMS Enterprise IDs (Each of them consists of host:port).

Instances List<Pulumi.AliCloud.Dms.Outputs.GetEnterpriseInstancesInstance>

A list of KMS keys. Each element contains the following attributes:

Names List<string>

A list of DMS Enterprise names.

EnvType string

The type of the environment to which the database instance belongs..

InstanceAliasRegex string
InstanceSource string

The ID of the database instance.

InstanceType string

The ID of the database instance.

NameRegex string
NetType string
OutputFile string
SearchKey string
Status string

The status of the database instance.

Tid int
Id string

The provider-assigned unique ID for this managed resource.

Ids []string

A list of DMS Enterprise IDs (Each of them consists of host:port).

Instances []GetEnterpriseInstancesInstance

A list of KMS keys. Each element contains the following attributes:

Names []string

A list of DMS Enterprise names.

EnvType string

The type of the environment to which the database instance belongs..

InstanceAliasRegex string
InstanceSource string

The ID of the database instance.

InstanceType string

The ID of the database instance.

NameRegex string
NetType string
OutputFile string
SearchKey string
Status string

The status of the database instance.

Tid int
id String

The provider-assigned unique ID for this managed resource.

ids List

A list of DMS Enterprise IDs (Each of them consists of host:port).

instances ListEnterpriseInstancesInstance>

A list of KMS keys. Each element contains the following attributes:

names List

A list of DMS Enterprise names.

envType String

The type of the environment to which the database instance belongs..

instanceAliasRegex String
instanceSource String

The ID of the database instance.

instanceType String

The ID of the database instance.

nameRegex String
netType String
outputFile String
searchKey String
status String

The status of the database instance.

tid Integer
id string

The provider-assigned unique ID for this managed resource.

ids string[]

A list of DMS Enterprise IDs (Each of them consists of host:port).

instances GetEnterpriseInstancesInstance[]

A list of KMS keys. Each element contains the following attributes:

names string[]

A list of DMS Enterprise names.

envType string

The type of the environment to which the database instance belongs..

instanceAliasRegex string
instanceSource string

The ID of the database instance.

instanceType string

The ID of the database instance.

nameRegex string
netType string
outputFile string
searchKey string
status string

The status of the database instance.

tid number
id str

The provider-assigned unique ID for this managed resource.

ids Sequence[str]

A list of DMS Enterprise IDs (Each of them consists of host:port).

instances Sequence[GetEnterpriseInstancesInstance]

A list of KMS keys. Each element contains the following attributes:

names Sequence[str]

A list of DMS Enterprise names.

env_type str

The type of the environment to which the database instance belongs..

instance_alias_regex str
instance_source str

The ID of the database instance.

instance_type str

The ID of the database instance.

name_regex str
net_type str
output_file str
search_key str
status str

The status of the database instance.

tid int
id String

The provider-assigned unique ID for this managed resource.

ids List

A list of DMS Enterprise IDs (Each of them consists of host:port).

instances List

A list of KMS keys. Each element contains the following attributes:

names List

A list of DMS Enterprise names.

envType String

The type of the environment to which the database instance belongs..

instanceAliasRegex String
instanceSource String

The ID of the database instance.

instanceType String

The ID of the database instance.

nameRegex String
netType String
outputFile String
searchKey String
status String

The status of the database instance.

tid Number

Supporting Types

GetEnterpriseInstancesInstance

DataLinkName string

The name of the data link for the database instance.

DatabasePassword string

The logon password of the database instance.

DatabaseUser string

The logon username of the database instance.

DbaId string

The ID of the database administrator (DBA) of the database instance.

DbaNickName string

The nickname of the DBA.

DdlOnline int

Indicates whether the online data description language (DDL) service was enabled for the database instance.

EcsInstanceId string

The ID of the Elastic Compute Service (ECS) instance to which the database instance belongs.

EcsRegion string

The region where the database instance resides.

EnvType string

The type of the environment to which the database instance belongs.

ExportTimeout int

The timeout period for exporting the database instance.

Host string

The endpoint of the database instance.

Id string
InstanceAlias string

The alias of the database instance.

InstanceId string

The ID of the database instance.

InstanceName string
InstanceSource string

The source of the database instance.

InstanceType string

The ID of the database instance.

Port int

The connection port of the database instance.

QueryTimeout int

The timeout period for querying the database instance.

SafeRuleId string

The ID of the security rule for the database instance.

Sid string

The system ID (SID) of the database instance.

Status string

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

UseDsql int

Indicates whether cross-database query was enabled for the database instance.

VpcId string

The ID of the Virtual Private Cloud (VPC) to which the database instance belongs.

DataLinkName string

The name of the data link for the database instance.

DatabasePassword string

The logon password of the database instance.

DatabaseUser string

The logon username of the database instance.

DbaId string

The ID of the database administrator (DBA) of the database instance.

DbaNickName string

The nickname of the DBA.

DdlOnline int

Indicates whether the online data description language (DDL) service was enabled for the database instance.

EcsInstanceId string

The ID of the Elastic Compute Service (ECS) instance to which the database instance belongs.

EcsRegion string

The region where the database instance resides.

EnvType string

The type of the environment to which the database instance belongs.

ExportTimeout int

The timeout period for exporting the database instance.

Host string

The endpoint of the database instance.

Id string
InstanceAlias string

The alias of the database instance.

InstanceId string

The ID of the database instance.

InstanceName string
InstanceSource string

The source of the database instance.

InstanceType string

The ID of the database instance.

Port int

The connection port of the database instance.

QueryTimeout int

The timeout period for querying the database instance.

SafeRuleId string

The ID of the security rule for the database instance.

Sid string

The system ID (SID) of the database instance.

Status string

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

UseDsql int

Indicates whether cross-database query was enabled for the database instance.

VpcId string

The ID of the Virtual Private Cloud (VPC) to which the database instance belongs.

dataLinkName String

The name of the data link for the database instance.

databasePassword String

The logon password of the database instance.

databaseUser String

The logon username of the database instance.

dbaId String

The ID of the database administrator (DBA) of the database instance.

dbaNickName String

The nickname of the DBA.

ddlOnline Integer

Indicates whether the online data description language (DDL) service was enabled for the database instance.

ecsInstanceId String

The ID of the Elastic Compute Service (ECS) instance to which the database instance belongs.

ecsRegion String

The region where the database instance resides.

envType String

The type of the environment to which the database instance belongs.

exportTimeout Integer

The timeout period for exporting the database instance.

host String

The endpoint of the database instance.

id String
instanceAlias String

The alias of the database instance.

instanceId String

The ID of the database instance.

instanceName String
instanceSource String

The source of the database instance.

instanceType String

The ID of the database instance.

port Integer

The connection port of the database instance.

queryTimeout Integer

The timeout period for querying the database instance.

safeRuleId String

The ID of the security rule for the database instance.

sid String

The system ID (SID) of the database instance.

status String

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

useDsql Integer

Indicates whether cross-database query was enabled for the database instance.

vpcId String

The ID of the Virtual Private Cloud (VPC) to which the database instance belongs.

dataLinkName string

The name of the data link for the database instance.

databasePassword string

The logon password of the database instance.

databaseUser string

The logon username of the database instance.

dbaId string

The ID of the database administrator (DBA) of the database instance.

dbaNickName string

The nickname of the DBA.

ddlOnline number

Indicates whether the online data description language (DDL) service was enabled for the database instance.

ecsInstanceId string

The ID of the Elastic Compute Service (ECS) instance to which the database instance belongs.

ecsRegion string

The region where the database instance resides.

envType string

The type of the environment to which the database instance belongs.

exportTimeout number

The timeout period for exporting the database instance.

host string

The endpoint of the database instance.

id string
instanceAlias string

The alias of the database instance.

instanceId string

The ID of the database instance.

instanceName string
instanceSource string

The source of the database instance.

instanceType string

The ID of the database instance.

port number

The connection port of the database instance.

queryTimeout number

The timeout period for querying the database instance.

safeRuleId string

The ID of the security rule for the database instance.

sid string

The system ID (SID) of the database instance.

status string

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

useDsql number

Indicates whether cross-database query was enabled for the database instance.

vpcId string

The ID of the Virtual Private Cloud (VPC) to which the database instance belongs.

data_link_name str

The name of the data link for the database instance.

database_password str

The logon password of the database instance.

database_user str

The logon username of the database instance.

dba_id str

The ID of the database administrator (DBA) of the database instance.

dba_nick_name str

The nickname of the DBA.

ddl_online int

Indicates whether the online data description language (DDL) service was enabled for the database instance.

ecs_instance_id str

The ID of the Elastic Compute Service (ECS) instance to which the database instance belongs.

ecs_region str

The region where the database instance resides.

env_type str

The type of the environment to which the database instance belongs.

export_timeout int

The timeout period for exporting the database instance.

host str

The endpoint of the database instance.

id str
instance_alias str

The alias of the database instance.

instance_id str

The ID of the database instance.

instance_name str
instance_source str

The source of the database instance.

instance_type str

The ID of the database instance.

port int

The connection port of the database instance.

query_timeout int

The timeout period for querying the database instance.

safe_rule_id str

The ID of the security rule for the database instance.

sid str

The system ID (SID) of the database instance.

status str

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

use_dsql int

Indicates whether cross-database query was enabled for the database instance.

vpc_id str

The ID of the Virtual Private Cloud (VPC) to which the database instance belongs.

dataLinkName String

The name of the data link for the database instance.

databasePassword String

The logon password of the database instance.

databaseUser String

The logon username of the database instance.

dbaId String

The ID of the database administrator (DBA) of the database instance.

dbaNickName String

The nickname of the DBA.

ddlOnline Number

Indicates whether the online data description language (DDL) service was enabled for the database instance.

ecsInstanceId String

The ID of the Elastic Compute Service (ECS) instance to which the database instance belongs.

ecsRegion String

The region where the database instance resides.

envType String

The type of the environment to which the database instance belongs.

exportTimeout Number

The timeout period for exporting the database instance.

host String

The endpoint of the database instance.

id String
instanceAlias String

The alias of the database instance.

instanceId String

The ID of the database instance.

instanceName String
instanceSource String

The source of the database instance.

instanceType String

The ID of the database instance.

port Number

The connection port of the database instance.

queryTimeout Number

The timeout period for querying the database instance.

safeRuleId String

The ID of the security rule for the database instance.

sid String

The system ID (SID) of the database instance.

status String

Filter the results by status of the DMS Enterprise Instances. Valid values: NORMAL, UNAVAILABLE, UNKNOWN, DELETED, DISABLE.

useDsql Number

Indicates whether cross-database query was enabled for the database instance.

vpcId String

The ID of the Virtual Private Cloud (VPC) to which the database instance belongs.

Package Details

Repository
https://github.com/pulumi/pulumi-alicloud
License
Apache-2.0
Notes

This Pulumi package is based on the alicloud Terraform Provider.