Alibaba Cloud v3.57.1 published on Wednesday, Jun 26, 2024 by Pulumi
alicloud.mse.getClusters
Explore with Pulumi AI
This data source provides a list of MSE Clusters in an Alibaba Cloud account according to the specified filters.
NOTE: Available in v1.94.0+.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
// Declare the data source
const example = alicloud.mse.getClusters({
ids: ["mse-cn-0d9xxxx"],
status: "INIT_SUCCESS",
});
export const clusterId = example.then(example => example.clusters?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
# Declare the data source
example = alicloud.mse.get_clusters(ids=["mse-cn-0d9xxxx"],
status="INIT_SUCCESS")
pulumi.export("clusterId", example.clusters[0].id)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/mse"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
// Declare the data source
example, err := mse.GetClusters(ctx, &mse.GetClustersArgs{
Ids: []string{
"mse-cn-0d9xxxx",
},
Status: pulumi.StringRef("INIT_SUCCESS"),
}, nil)
if err != nil {
return err
}
ctx.Export("clusterId", example.Clusters[0].Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
// Declare the data source
var example = AliCloud.Mse.GetClusters.Invoke(new()
{
Ids = new[]
{
"mse-cn-0d9xxxx",
},
Status = "INIT_SUCCESS",
});
return new Dictionary<string, object?>
{
["clusterId"] = example.Apply(getClustersResult => getClustersResult.Clusters[0]?.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.mse.MseFunctions;
import com.pulumi.alicloud.mse.inputs.GetClustersArgs;
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) {
// Declare the data source
final var example = MseFunctions.getClusters(GetClustersArgs.builder()
.ids("mse-cn-0d9xxxx")
.status("INIT_SUCCESS")
.build());
ctx.export("clusterId", example.applyValue(getClustersResult -> getClustersResult.clusters()[0].id()));
}
}
variables:
# Declare the data source
example:
fn::invoke:
Function: alicloud:mse:getClusters
Arguments:
ids:
- mse-cn-0d9xxxx
status: INIT_SUCCESS
outputs:
clusterId: ${example.clusters[0].id}
Using getClusters
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 getClusters(args: GetClustersArgs, opts?: InvokeOptions): Promise<GetClustersResult>
function getClustersOutput(args: GetClustersOutputArgs, opts?: InvokeOptions): Output<GetClustersResult>
def get_clusters(cluster_alias_name: Optional[str] = None,
enable_details: Optional[bool] = None,
ids: Optional[Sequence[str]] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
request_pars: Optional[str] = None,
status: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetClustersResult
def get_clusters_output(cluster_alias_name: Optional[pulumi.Input[str]] = None,
enable_details: Optional[pulumi.Input[bool]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
name_regex: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
request_pars: Optional[pulumi.Input[str]] = None,
status: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetClustersResult]
func GetClusters(ctx *Context, args *GetClustersArgs, opts ...InvokeOption) (*GetClustersResult, error)
func GetClustersOutput(ctx *Context, args *GetClustersOutputArgs, opts ...InvokeOption) GetClustersResultOutput
> Note: This function is named GetClusters
in the Go SDK.
public static class GetClusters
{
public static Task<GetClustersResult> InvokeAsync(GetClustersArgs args, InvokeOptions? opts = null)
public static Output<GetClustersResult> Invoke(GetClustersInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetClustersResult> getClusters(GetClustersArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:mse/getClusters:getClusters
arguments:
# arguments dictionary
The following arguments are supported:
- Cluster
Alias stringName - The alias name of MSE Cluster.
- Enable
Details bool - Ids List<string>
- A list of MSE Cluster ids.
- Name
Regex string - A regex string to filter the results by the cluster alias name.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Request
Pars string - Status string
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- Cluster
Alias stringName - The alias name of MSE Cluster.
- Enable
Details bool - Ids []string
- A list of MSE Cluster ids.
- Name
Regex string - A regex string to filter the results by the cluster alias name.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Request
Pars string - Status string
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- cluster
Alias StringName - The alias name of MSE Cluster.
- enable
Details Boolean - ids List<String>
- A list of MSE Cluster ids.
- name
Regex String - A regex string to filter the results by the cluster alias name.
- output
File String - File name where to save data source results (after running
pulumi preview
). - request
Pars String - status String
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- cluster
Alias stringName - The alias name of MSE Cluster.
- enable
Details boolean - ids string[]
- A list of MSE Cluster ids.
- name
Regex string - A regex string to filter the results by the cluster alias name.
- output
File string - File name where to save data source results (after running
pulumi preview
). - request
Pars string - status string
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- cluster_
alias_ strname - The alias name of MSE Cluster.
- enable_
details bool - ids Sequence[str]
- A list of MSE Cluster ids.
- name_
regex str - A regex string to filter the results by the cluster alias name.
- output_
file str - File name where to save data source results (after running
pulumi preview
). - request_
pars str - status str
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- cluster
Alias StringName - The alias name of MSE Cluster.
- enable
Details Boolean - ids List<String>
- A list of MSE Cluster ids.
- name
Regex String - A regex string to filter the results by the cluster alias name.
- output
File String - File name where to save data source results (after running
pulumi preview
). - request
Pars String - status String
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
getClusters Result
The following output properties are available:
- Clusters
List<Pulumi.
Ali Cloud. Mse. Outputs. Get Clusters Cluster> - A list of MSE Clusters. Each element contains the following attributes:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- A list of MSE Cluster ids.
- Names List<string>
- A list of MSE Cluster names.
- Cluster
Alias stringName - Enable
Details bool - Name
Regex string - Output
File string - Request
Pars string - Status string
- The status of MSE Cluster.
- Clusters
[]Get
Clusters Cluster - A list of MSE Clusters. Each element contains the following attributes:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- A list of MSE Cluster ids.
- Names []string
- A list of MSE Cluster names.
- Cluster
Alias stringName - Enable
Details bool - Name
Regex string - Output
File string - Request
Pars string - Status string
- The status of MSE Cluster.
- clusters
List<Get
Clusters Cluster> - A list of MSE Clusters. Each element contains the following attributes:
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- A list of MSE Cluster ids.
- names List<String>
- A list of MSE Cluster names.
- cluster
Alias StringName - enable
Details Boolean - name
Regex String - output
File String - request
Pars String - status String
- The status of MSE Cluster.
- clusters
Get
Clusters Cluster[] - A list of MSE Clusters. Each element contains the following attributes:
- id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- A list of MSE Cluster ids.
- names string[]
- A list of MSE Cluster names.
- cluster
Alias stringName - enable
Details boolean - name
Regex string - output
File string - request
Pars string - status string
- The status of MSE Cluster.
- clusters
Sequence[Get
Clusters Cluster] - A list of MSE Clusters. Each element contains the following attributes:
- id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- A list of MSE Cluster ids.
- names Sequence[str]
- A list of MSE Cluster names.
- cluster_
alias_ strname - enable_
details bool - name_
regex str - output_
file str - request_
pars str - status str
- The status of MSE Cluster.
- clusters List<Property Map>
- A list of MSE Clusters. Each element contains the following attributes:
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- A list of MSE Cluster ids.
- names List<String>
- A list of MSE Cluster names.
- cluster
Alias StringName - enable
Details Boolean - name
Regex String - output
File String - request
Pars String - status String
- The status of MSE Cluster.
Supporting Types
GetClustersCluster
- Acl
Id string - The id of acl.
- App
Version string - The version of app.
- Cluster
Id string - ID of the MSE Cluster.
- Cluster
Name string - ID of the OOS Executions.
- Cluster
Type string - The type of MSE Cluster.
- Cpu int
- The num of cpu.
- Health
Status string - The health status of MSE Cluster.
- Id string
- ID of the MSE Cluster.
- Init
Cost intTime - Time-consuming to create.
- Instance
Count int - The count of instance.
- Instance
Id string - ID of the MSE Cluster.
- Instance
Models List<Pulumi.Ali Cloud. Mse. Inputs. Get Clusters Cluster Instance Model> - The list of instances.
- Internet
Address string - The address of public network.
- Internet
Domain string - The domain of public network.
- Internet
Port string - The port of public network.
- Intranet
Address string - The address of private network.
- Intranet
Domain string - The domain of private network.
- Intranet
Port string - The port of private network.
- Memory
Capacity int - The memory size.
- Pay
Info string - The type of payment.
- Pub
Network stringFlow - The public network bandwidth.
- Status string
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- Acl
Id string - The id of acl.
- App
Version string - The version of app.
- Cluster
Id string - ID of the MSE Cluster.
- Cluster
Name string - ID of the OOS Executions.
- Cluster
Type string - The type of MSE Cluster.
- Cpu int
- The num of cpu.
- Health
Status string - The health status of MSE Cluster.
- Id string
- ID of the MSE Cluster.
- Init
Cost intTime - Time-consuming to create.
- Instance
Count int - The count of instance.
- Instance
Id string - ID of the MSE Cluster.
- Instance
Models []GetClusters Cluster Instance Model - The list of instances.
- Internet
Address string - The address of public network.
- Internet
Domain string - The domain of public network.
- Internet
Port string - The port of public network.
- Intranet
Address string - The address of private network.
- Intranet
Domain string - The domain of private network.
- Intranet
Port string - The port of private network.
- Memory
Capacity int - The memory size.
- Pay
Info string - The type of payment.
- Pub
Network stringFlow - The public network bandwidth.
- Status string
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- acl
Id String - The id of acl.
- app
Version String - The version of app.
- cluster
Id String - ID of the MSE Cluster.
- cluster
Name String - ID of the OOS Executions.
- cluster
Type String - The type of MSE Cluster.
- cpu Integer
- The num of cpu.
- health
Status String - The health status of MSE Cluster.
- id String
- ID of the MSE Cluster.
- init
Cost IntegerTime - Time-consuming to create.
- instance
Count Integer - The count of instance.
- instance
Id String - ID of the MSE Cluster.
- instance
Models List<GetClusters Cluster Instance Model> - The list of instances.
- internet
Address String - The address of public network.
- internet
Domain String - The domain of public network.
- internet
Port String - The port of public network.
- intranet
Address String - The address of private network.
- intranet
Domain String - The domain of private network.
- intranet
Port String - The port of private network.
- memory
Capacity Integer - The memory size.
- pay
Info String - The type of payment.
- pub
Network StringFlow - The public network bandwidth.
- status String
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- acl
Id string - The id of acl.
- app
Version string - The version of app.
- cluster
Id string - ID of the MSE Cluster.
- cluster
Name string - ID of the OOS Executions.
- cluster
Type string - The type of MSE Cluster.
- cpu number
- The num of cpu.
- health
Status string - The health status of MSE Cluster.
- id string
- ID of the MSE Cluster.
- init
Cost numberTime - Time-consuming to create.
- instance
Count number - The count of instance.
- instance
Id string - ID of the MSE Cluster.
- instance
Models GetClusters Cluster Instance Model[] - The list of instances.
- internet
Address string - The address of public network.
- internet
Domain string - The domain of public network.
- internet
Port string - The port of public network.
- intranet
Address string - The address of private network.
- intranet
Domain string - The domain of private network.
- intranet
Port string - The port of private network.
- memory
Capacity number - The memory size.
- pay
Info string - The type of payment.
- pub
Network stringFlow - The public network bandwidth.
- status string
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- acl_
id str - The id of acl.
- app_
version str - The version of app.
- cluster_
id str - ID of the MSE Cluster.
- cluster_
name str - ID of the OOS Executions.
- cluster_
type str - The type of MSE Cluster.
- cpu int
- The num of cpu.
- health_
status str - The health status of MSE Cluster.
- id str
- ID of the MSE Cluster.
- init_
cost_ inttime - Time-consuming to create.
- instance_
count int - The count of instance.
- instance_
id str - ID of the MSE Cluster.
- instance_
models Sequence[GetClusters Cluster Instance Model] - The list of instances.
- internet_
address str - The address of public network.
- internet_
domain str - The domain of public network.
- internet_
port str - The port of public network.
- intranet_
address str - The address of private network.
- intranet_
domain str - The domain of private network.
- intranet_
port str - The port of private network.
- memory_
capacity int - The memory size.
- pay_
info str - The type of payment.
- pub_
network_ strflow - The public network bandwidth.
- status str
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
- acl
Id String - The id of acl.
- app
Version String - The version of app.
- cluster
Id String - ID of the MSE Cluster.
- cluster
Name String - ID of the OOS Executions.
- cluster
Type String - The type of MSE Cluster.
- cpu Number
- The num of cpu.
- health
Status String - The health status of MSE Cluster.
- id String
- ID of the MSE Cluster.
- init
Cost NumberTime - Time-consuming to create.
- instance
Count Number - The count of instance.
- instance
Id String - ID of the MSE Cluster.
- instance
Models List<Property Map> - The list of instances.
- internet
Address String - The address of public network.
- internet
Domain String - The domain of public network.
- internet
Port String - The port of public network.
- intranet
Address String - The address of private network.
- intranet
Domain String - The domain of private network.
- intranet
Port String - The port of private network.
- memory
Capacity Number - The memory size.
- pay
Info String - The type of payment.
- pub
Network StringFlow - The public network bandwidth.
- status String
- The status of MSE Cluster. Valid:
DESTROY_FAILED
,DESTROY_ING
,DESTROY_SUCCESS
,INIT_FAILED
,INIT_ING
,INIT_SUCCESS
,INIT_TIME_OUT
,RESTART_FAILED
,RESTART_ING
,RESTART_SUCCESS
,SCALE_FAILED
,SCALE_ING
,SCALE_SUCCESS
GetClustersClusterInstanceModel
- Health
Status string - The health status of MSE Cluster.
- Instance
Type string - Internet
Ip string - Ip string
- Pod
Name string - Role string
- Single
Tunnel stringVip - Vip string
- Health
Status string - The health status of MSE Cluster.
- Instance
Type string - Internet
Ip string - Ip string
- Pod
Name string - Role string
- Single
Tunnel stringVip - Vip string
- health
Status String - The health status of MSE Cluster.
- instance
Type String - internet
Ip String - ip String
- pod
Name String - role String
- single
Tunnel StringVip - vip String
- health
Status string - The health status of MSE Cluster.
- instance
Type string - internet
Ip string - ip string
- pod
Name string - role string
- single
Tunnel stringVip - vip string
- health_
status str - The health status of MSE Cluster.
- instance_
type str - internet_
ip str - ip str
- pod_
name str - role str
- single_
tunnel_ strvip - vip str
- health
Status String - The health status of MSE Cluster.
- instance
Type String - internet
Ip String - ip String
- pod
Name String - role String
- single
Tunnel StringVip - vip String
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.