alicloud.polardb.getParameterGroups
This data source provides the PolarDB Parameter Groups of the current Alibaba Cloud user.
NOTE: Available in v1.183.0+.
Example Usage
Basic Usage
using System.Collections.Generic;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var ids = AliCloud.PolarDB.GetParameterGroups.Invoke(new()
{
Ids = new[]
{
"example_id",
},
});
var nameRegex = AliCloud.PolarDB.GetParameterGroups.Invoke(new()
{
NameRegex = "example_name",
});
return new Dictionary<string, object?>
{
["polardbParameterGroupId1"] = ids.Apply(getParameterGroupsResult => getParameterGroupsResult.Groups[0]?.Id),
["polardbParameterGroupId2"] = nameRegex.Apply(getParameterGroupsResult => getParameterGroupsResult.Groups[0]?.Id),
};
});
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/polardb"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
ids, err := polardb.GetParameterGroups(ctx, &polardb.GetParameterGroupsArgs{
Ids: []string{
"example_id",
},
}, nil)
if err != nil {
return err
}
ctx.Export("polardbParameterGroupId1", ids.Groups[0].Id)
nameRegex, err := polardb.GetParameterGroups(ctx, &polardb.GetParameterGroupsArgs{
NameRegex: pulumi.StringRef("example_name"),
}, nil)
if err != nil {
return err
}
ctx.Export("polardbParameterGroupId2", nameRegex.Groups[0].Id)
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.polardb.PolardbFunctions;
import com.pulumi.alicloud.polardb.inputs.GetParameterGroupsArgs;
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 ids = PolardbFunctions.getParameterGroups(GetParameterGroupsArgs.builder()
.ids("example_id")
.build());
ctx.export("polardbParameterGroupId1", ids.applyValue(getParameterGroupsResult -> getParameterGroupsResult.groups()[0].id()));
final var nameRegex = PolardbFunctions.getParameterGroups(GetParameterGroupsArgs.builder()
.nameRegex("example_name")
.build());
ctx.export("polardbParameterGroupId2", nameRegex.applyValue(getParameterGroupsResult -> getParameterGroupsResult.groups()[0].id()));
}
}
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.polardb.get_parameter_groups(ids=["example_id"])
pulumi.export("polardbParameterGroupId1", ids.groups[0].id)
name_regex = alicloud.polardb.get_parameter_groups(name_regex="example_name")
pulumi.export("polardbParameterGroupId2", name_regex.groups[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.polardb.getParameterGroups({
ids: ["example_id"],
});
export const polardbParameterGroupId1 = ids.then(ids => ids.groups?.[0]?.id);
const nameRegex = alicloud.polardb.getParameterGroups({
nameRegex: "example_name",
});
export const polardbParameterGroupId2 = nameRegex.then(nameRegex => nameRegex.groups?.[0]?.id);
variables:
ids:
fn::invoke:
Function: alicloud:polardb:getParameterGroups
Arguments:
ids:
- example_id
nameRegex:
fn::invoke:
Function: alicloud:polardb:getParameterGroups
Arguments:
nameRegex: example_name
outputs:
polardbParameterGroupId1: ${ids.groups[0].id}
polardbParameterGroupId2: ${nameRegex.groups[0].id}
Using getParameterGroups
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 getParameterGroups(args: GetParameterGroupsArgs, opts?: InvokeOptions): Promise<GetParameterGroupsResult>
function getParameterGroupsOutput(args: GetParameterGroupsOutputArgs, opts?: InvokeOptions): Output<GetParameterGroupsResult>
def get_parameter_groups(db_type: Optional[str] = None,
db_version: Optional[str] = None,
ids: Optional[Sequence[str]] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetParameterGroupsResult
def get_parameter_groups_output(db_type: Optional[pulumi.Input[str]] = None,
db_version: Optional[pulumi.Input[str]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
name_regex: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetParameterGroupsResult]
func GetParameterGroups(ctx *Context, args *GetParameterGroupsArgs, opts ...InvokeOption) (*GetParameterGroupsResult, error)
func GetParameterGroupsOutput(ctx *Context, args *GetParameterGroupsOutputArgs, opts ...InvokeOption) GetParameterGroupsResultOutput
> Note: This function is named GetParameterGroups
in the Go SDK.
public static class GetParameterGroups
{
public static Task<GetParameterGroupsResult> InvokeAsync(GetParameterGroupsArgs args, InvokeOptions? opts = null)
public static Output<GetParameterGroupsResult> Invoke(GetParameterGroupsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetParameterGroupsResult> getParameterGroups(GetParameterGroupsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:polardb/getParameterGroups:getParameterGroups
arguments:
# arguments dictionary
The following arguments are supported:
- Db
Type string The type of the database engine.
- Db
Version string The version number of the database engine.
- Ids List<string>
A list of Parameter Group IDs.
- Name
Regex string A regex string to filter results by Parameter Group name.
- Output
File string
- Db
Type string The type of the database engine.
- Db
Version string The version number of the database engine.
- Ids []string
A list of Parameter Group IDs.
- Name
Regex string A regex string to filter results by Parameter Group name.
- Output
File string
- db
Type String The type of the database engine.
- db
Version String The version number of the database engine.
- ids List<String>
A list of Parameter Group IDs.
- name
Regex String A regex string to filter results by Parameter Group name.
- output
File String
- db
Type string The type of the database engine.
- db
Version string The version number of the database engine.
- ids string[]
A list of Parameter Group IDs.
- name
Regex string A regex string to filter results by Parameter Group name.
- output
File string
- db_
type str The type of the database engine.
- db_
version str The version number of the database engine.
- ids Sequence[str]
A list of Parameter Group IDs.
- name_
regex str A regex string to filter results by Parameter Group name.
- output_
file str
- db
Type String The type of the database engine.
- db
Version String The version number of the database engine.
- ids List<String>
A list of Parameter Group IDs.
- name
Regex String A regex string to filter results by Parameter Group name.
- output
File String
getParameterGroups Result
The following output properties are available:
- Groups
List<Pulumi.
Ali Cloud. Polar DB. Outputs. Get Parameter Groups Group> - Id string
The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Names List<string>
- Db
Type string - Db
Version string - Name
Regex string - Output
File string
- Groups
[]Get
Parameter Groups Group - Id string
The provider-assigned unique ID for this managed resource.
- Ids []string
- Names []string
- Db
Type string - Db
Version string - Name
Regex string - Output
File string
- groups
List<Get
Parameter Groups Group> - id String
The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- db
Type String - db
Version String - name
Regex String - output
File String
- groups
Get
Parameter Groups Group[] - id string
The provider-assigned unique ID for this managed resource.
- ids string[]
- names string[]
- db
Type string - db
Version string - name
Regex string - output
File string
- groups
Sequence[Get
Parameter Groups Group] - id str
The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- names Sequence[str]
- db_
type str - db_
version str - name_
regex str - output_
file str
- groups List<Property Map>
- id String
The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- db
Type String - db
Version String - name
Regex String - output
File String
Supporting Types
GetParameterGroupsGroup
- Create
Time string The time when the parameter template was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.
- Db
Type string The type of the database engine.
- Db
Version string The version number of the database engine.
- Force
Restart string Indicates whether to restart the cluster when this parameter template is applied.
- Id string
The ID of the Parameter Group.
- Parameter
Counts int The number of parameters in the parameter template.
- Parameter
Group stringDesc The description of the parameter template.
- Parameter
Group stringId The ID of the Parameter Group.
- Parameter
Group stringName The name of the parameter template.
- Parameter
Group stringType The type of the parameter template.
- Create
Time string The time when the parameter template was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.
- Db
Type string The type of the database engine.
- Db
Version string The version number of the database engine.
- Force
Restart string Indicates whether to restart the cluster when this parameter template is applied.
- Id string
The ID of the Parameter Group.
- Parameter
Counts int The number of parameters in the parameter template.
- Parameter
Group stringDesc The description of the parameter template.
- Parameter
Group stringId The ID of the Parameter Group.
- Parameter
Group stringName The name of the parameter template.
- Parameter
Group stringType The type of the parameter template.
- create
Time String The time when the parameter template was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.
- db
Type String The type of the database engine.
- db
Version String The version number of the database engine.
- force
Restart String Indicates whether to restart the cluster when this parameter template is applied.
- id String
The ID of the Parameter Group.
- parameter
Counts Integer The number of parameters in the parameter template.
- parameter
Group StringDesc The description of the parameter template.
- parameter
Group StringId The ID of the Parameter Group.
- parameter
Group StringName The name of the parameter template.
- parameter
Group StringType The type of the parameter template.
- create
Time string The time when the parameter template was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.
- db
Type string The type of the database engine.
- db
Version string The version number of the database engine.
- force
Restart string Indicates whether to restart the cluster when this parameter template is applied.
- id string
The ID of the Parameter Group.
- parameter
Counts number The number of parameters in the parameter template.
- parameter
Group stringDesc The description of the parameter template.
- parameter
Group stringId The ID of the Parameter Group.
- parameter
Group stringName The name of the parameter template.
- parameter
Group stringType The type of the parameter template.
- create_
time str The time when the parameter template was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.
- db_
type str The type of the database engine.
- db_
version str The version number of the database engine.
- force_
restart str Indicates whether to restart the cluster when this parameter template is applied.
- id str
The ID of the Parameter Group.
- parameter_
counts int The number of parameters in the parameter template.
- parameter_
group_ strdesc The description of the parameter template.
- parameter_
group_ strid The ID of the Parameter Group.
- parameter_
group_ strname The name of the parameter template.
- parameter_
group_ strtype The type of the parameter template.
- create
Time String The time when the parameter template was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.
- db
Type String The type of the database engine.
- db
Version String The version number of the database engine.
- force
Restart String Indicates whether to restart the cluster when this parameter template is applied.
- id String
The ID of the Parameter Group.
- parameter
Counts Number The number of parameters in the parameter template.
- parameter
Group StringDesc The description of the parameter template.
- parameter
Group StringId The ID of the Parameter Group.
- parameter
Group StringName The name of the parameter template.
- parameter
Group StringType The type of the parameter template.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
alicloud
Terraform Provider.