AWS v6.54.2 published on Wednesday, Oct 2, 2024 by Pulumi
aws.rds.getClusters
Explore with Pulumi AI
Data source for managing an AWS RDS (Relational Database) Clusters.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = aws.rds.getClusters({
filters: [{
name: "engine",
values: ["aurora-postgresql"],
}],
});
import pulumi
import pulumi_aws as aws
example = aws.rds.get_clusters(filters=[{
"name": "engine",
"values": ["aurora-postgresql"],
}])
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/rds"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := rds.GetClusters(ctx, &rds.GetClustersArgs{
Filters: []rds.GetClustersFilter{
{
Name: "engine",
Values: []string{
"aurora-postgresql",
},
},
},
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = Aws.Rds.GetClusters.Invoke(new()
{
Filters = new[]
{
new Aws.Rds.Inputs.GetClustersFilterInputArgs
{
Name = "engine",
Values = new[]
{
"aurora-postgresql",
},
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.rds.RdsFunctions;
import com.pulumi.aws.rds.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) {
final var example = RdsFunctions.getClusters(GetClustersArgs.builder()
.filters(GetClustersFilterArgs.builder()
.name("engine")
.values("aurora-postgresql")
.build())
.build());
}
}
variables:
example:
fn::invoke:
Function: aws:rds:getClusters
Arguments:
filters:
- name: engine
values:
- aurora-postgresql
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(filters: Optional[Sequence[GetClustersFilter]] = None,
opts: Optional[InvokeOptions] = None) -> GetClustersResult
def get_clusters_output(filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetClustersFilterArgs]]]] = 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: aws:rds/getClusters:getClusters
arguments:
# arguments dictionary
The following arguments are supported:
- Filters
List<Get
Clusters Filter> - Configuration block(s) for filtering. Detailed below.
- Filters
[]Get
Clusters Filter - Configuration block(s) for filtering. Detailed below.
- filters
List<Get
Clusters Filter> - Configuration block(s) for filtering. Detailed below.
- filters
Get
Clusters Filter[] - Configuration block(s) for filtering. Detailed below.
- filters
Sequence[Get
Clusters Filter] - Configuration block(s) for filtering. Detailed below.
- filters List<Property Map>
- Configuration block(s) for filtering. Detailed below.
getClusters Result
The following output properties are available:
- Cluster
Arns List<string> - Set of cluster ARNs of the matched RDS clusters.
- Cluster
Identifiers List<string> - Set of ARNs of cluster identifiers of the matched RDS clusters.
- Id string
- The provider-assigned unique ID for this managed resource.
- Filters
List<Get
Clusters Filter>
- Cluster
Arns []string - Set of cluster ARNs of the matched RDS clusters.
- Cluster
Identifiers []string - Set of ARNs of cluster identifiers of the matched RDS clusters.
- Id string
- The provider-assigned unique ID for this managed resource.
- Filters
[]Get
Clusters Filter
- cluster
Arns List<String> - Set of cluster ARNs of the matched RDS clusters.
- cluster
Identifiers List<String> - Set of ARNs of cluster identifiers of the matched RDS clusters.
- id String
- The provider-assigned unique ID for this managed resource.
- filters
List<Get
Clusters Filter>
- cluster
Arns string[] - Set of cluster ARNs of the matched RDS clusters.
- cluster
Identifiers string[] - Set of ARNs of cluster identifiers of the matched RDS clusters.
- id string
- The provider-assigned unique ID for this managed resource.
- filters
Get
Clusters Filter[]
- cluster_
arns Sequence[str] - Set of cluster ARNs of the matched RDS clusters.
- cluster_
identifiers Sequence[str] - Set of ARNs of cluster identifiers of the matched RDS clusters.
- id str
- The provider-assigned unique ID for this managed resource.
- filters
Sequence[Get
Clusters Filter]
- cluster
Arns List<String> - Set of cluster ARNs of the matched RDS clusters.
- cluster
Identifiers List<String> - Set of ARNs of cluster identifiers of the matched RDS clusters.
- id String
- The provider-assigned unique ID for this managed resource.
- filters List<Property Map>
Supporting Types
GetClustersFilter
- Name string
- Name of the filter field. Valid values can be found in the RDS DescribeDBClusters API Reference.
- Values List<string>
- Set of values that are accepted for the given filter field. Results will be selected if any given value matches.
- Name string
- Name of the filter field. Valid values can be found in the RDS DescribeDBClusters API Reference.
- Values []string
- Set of values that are accepted for the given filter field. Results will be selected if any given value matches.
- name String
- Name of the filter field. Valid values can be found in the RDS DescribeDBClusters API Reference.
- values List<String>
- Set of values that are accepted for the given filter field. Results will be selected if any given value matches.
- name string
- Name of the filter field. Valid values can be found in the RDS DescribeDBClusters API Reference.
- values string[]
- Set of values that are accepted for the given filter field. Results will be selected if any given value matches.
- name str
- Name of the filter field. Valid values can be found in the RDS DescribeDBClusters API Reference.
- values Sequence[str]
- Set of values that are accepted for the given filter field. Results will be selected if any given value matches.
- name String
- Name of the filter field. Valid values can be found in the RDS DescribeDBClusters API Reference.
- values List<String>
- Set of values that are accepted for the given filter field. Results will be selected if any given value matches.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.