1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. rds
  5. getInstanceEngines
Alibaba Cloud v3.66.0 published on Friday, Nov 15, 2024 by Pulumi

alicloud.rds.getInstanceEngines

Explore with Pulumi AI

alicloud logo
Alibaba Cloud v3.66.0 published on Friday, Nov 15, 2024 by Pulumi

    This data source provides the RDS instance engines resource available info of Alibaba Cloud.

    NOTE: Available in v1.46.0+

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as alicloud from "@pulumi/alicloud";
    
    const resources = alicloud.rds.getInstanceEngines({
        instanceChargeType: "PostPaid",
        engine: "MySQL",
        engineVersion: "5.6",
        outputFile: "./engines.txt",
    });
    export const firstDbCategory = resources.then(resources => resources.instanceEngines?.[0]?.category);
    
    import pulumi
    import pulumi_alicloud as alicloud
    
    resources = alicloud.rds.get_instance_engines(instance_charge_type="PostPaid",
        engine="MySQL",
        engine_version="5.6",
        output_file="./engines.txt")
    pulumi.export("firstDbCategory", resources.instance_engines[0].category)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/rds"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		resources, err := rds.GetInstanceEngines(ctx, &rds.GetInstanceEnginesArgs{
    			InstanceChargeType: pulumi.StringRef("PostPaid"),
    			Engine:             pulumi.StringRef("MySQL"),
    			EngineVersion:      pulumi.StringRef("5.6"),
    			OutputFile:         pulumi.StringRef("./engines.txt"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("firstDbCategory", resources.InstanceEngines[0].Category)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using AliCloud = Pulumi.AliCloud;
    
    return await Deployment.RunAsync(() => 
    {
        var resources = AliCloud.Rds.GetInstanceEngines.Invoke(new()
        {
            InstanceChargeType = "PostPaid",
            Engine = "MySQL",
            EngineVersion = "5.6",
            OutputFile = "./engines.txt",
        });
    
        return new Dictionary<string, object?>
        {
            ["firstDbCategory"] = resources.Apply(getInstanceEnginesResult => getInstanceEnginesResult.InstanceEngines[0]?.Category),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.alicloud.rds.RdsFunctions;
    import com.pulumi.alicloud.rds.inputs.GetInstanceEnginesArgs;
    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 resources = RdsFunctions.getInstanceEngines(GetInstanceEnginesArgs.builder()
                .instanceChargeType("PostPaid")
                .engine("MySQL")
                .engineVersion("5.6")
                .outputFile("./engines.txt")
                .build());
    
            ctx.export("firstDbCategory", resources.applyValue(getInstanceEnginesResult -> getInstanceEnginesResult.instanceEngines()[0].category()));
        }
    }
    
    variables:
      resources:
        fn::invoke:
          Function: alicloud:rds:getInstanceEngines
          Arguments:
            instanceChargeType: PostPaid
            engine: MySQL
            engineVersion: '5.6'
            outputFile: ./engines.txt
    outputs:
      firstDbCategory: ${resources.instanceEngines[0].category}
    

    Using getInstanceEngines

    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 getInstanceEngines(args: GetInstanceEnginesArgs, opts?: InvokeOptions): Promise<GetInstanceEnginesResult>
    function getInstanceEnginesOutput(args: GetInstanceEnginesOutputArgs, opts?: InvokeOptions): Output<GetInstanceEnginesResult>
    def get_instance_engines(category: Optional[str] = None,
                             db_instance_storage_type: Optional[str] = None,
                             engine: Optional[str] = None,
                             engine_version: Optional[str] = None,
                             instance_charge_type: Optional[str] = None,
                             multi_zone: Optional[bool] = None,
                             output_file: Optional[str] = None,
                             zone_id: Optional[str] = None,
                             opts: Optional[InvokeOptions] = None) -> GetInstanceEnginesResult
    def get_instance_engines_output(category: Optional[pulumi.Input[str]] = None,
                             db_instance_storage_type: Optional[pulumi.Input[str]] = None,
                             engine: Optional[pulumi.Input[str]] = None,
                             engine_version: Optional[pulumi.Input[str]] = None,
                             instance_charge_type: Optional[pulumi.Input[str]] = None,
                             multi_zone: Optional[pulumi.Input[bool]] = None,
                             output_file: Optional[pulumi.Input[str]] = None,
                             zone_id: Optional[pulumi.Input[str]] = None,
                             opts: Optional[InvokeOptions] = None) -> Output[GetInstanceEnginesResult]
    func GetInstanceEngines(ctx *Context, args *GetInstanceEnginesArgs, opts ...InvokeOption) (*GetInstanceEnginesResult, error)
    func GetInstanceEnginesOutput(ctx *Context, args *GetInstanceEnginesOutputArgs, opts ...InvokeOption) GetInstanceEnginesResultOutput

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

    public static class GetInstanceEngines 
    {
        public static Task<GetInstanceEnginesResult> InvokeAsync(GetInstanceEnginesArgs args, InvokeOptions? opts = null)
        public static Output<GetInstanceEnginesResult> Invoke(GetInstanceEnginesInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetInstanceEnginesResult> getInstanceEngines(GetInstanceEnginesArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: alicloud:rds/getInstanceEngines:getInstanceEngines
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Category string
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    DbInstanceStorageType string
    The DB instance storage space required by the user. Valid values: "cloud_ssd", "local_ssd", "cloud_essd", "cloud_essd2", "cloud_essd3".
    Engine string
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    EngineVersion string
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    InstanceChargeType string
    Filter the results by charge type. Valid values: PrePaid and PostPaid. Default to PostPaid.
    MultiZone bool
    Whether to show multi available zone. Default false to not show multi availability zone.
    OutputFile string
    File name where to save data source results (after running pulumi up).
    ZoneId string
    The Zone to launch the DB instance.
    Category string
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    DbInstanceStorageType string
    The DB instance storage space required by the user. Valid values: "cloud_ssd", "local_ssd", "cloud_essd", "cloud_essd2", "cloud_essd3".
    Engine string
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    EngineVersion string
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    InstanceChargeType string
    Filter the results by charge type. Valid values: PrePaid and PostPaid. Default to PostPaid.
    MultiZone bool
    Whether to show multi available zone. Default false to not show multi availability zone.
    OutputFile string
    File name where to save data source results (after running pulumi up).
    ZoneId string
    The Zone to launch the DB instance.
    category String
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    dbInstanceStorageType String
    The DB instance storage space required by the user. Valid values: "cloud_ssd", "local_ssd", "cloud_essd", "cloud_essd2", "cloud_essd3".
    engine String
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    engineVersion String
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    instanceChargeType String
    Filter the results by charge type. Valid values: PrePaid and PostPaid. Default to PostPaid.
    multiZone Boolean
    Whether to show multi available zone. Default false to not show multi availability zone.
    outputFile String
    File name where to save data source results (after running pulumi up).
    zoneId String
    The Zone to launch the DB instance.
    category string
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    dbInstanceStorageType string
    The DB instance storage space required by the user. Valid values: "cloud_ssd", "local_ssd", "cloud_essd", "cloud_essd2", "cloud_essd3".
    engine string
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    engineVersion string
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    instanceChargeType string
    Filter the results by charge type. Valid values: PrePaid and PostPaid. Default to PostPaid.
    multiZone boolean
    Whether to show multi available zone. Default false to not show multi availability zone.
    outputFile string
    File name where to save data source results (after running pulumi up).
    zoneId string
    The Zone to launch the DB instance.
    category str
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    db_instance_storage_type str
    The DB instance storage space required by the user. Valid values: "cloud_ssd", "local_ssd", "cloud_essd", "cloud_essd2", "cloud_essd3".
    engine str
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    engine_version str
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    instance_charge_type str
    Filter the results by charge type. Valid values: PrePaid and PostPaid. Default to PostPaid.
    multi_zone bool
    Whether to show multi available zone. Default false to not show multi availability zone.
    output_file str
    File name where to save data source results (after running pulumi up).
    zone_id str
    The Zone to launch the DB instance.
    category String
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    dbInstanceStorageType String
    The DB instance storage space required by the user. Valid values: "cloud_ssd", "local_ssd", "cloud_essd", "cloud_essd2", "cloud_essd3".
    engine String
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    engineVersion String
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    instanceChargeType String
    Filter the results by charge type. Valid values: PrePaid and PostPaid. Default to PostPaid.
    multiZone Boolean
    Whether to show multi available zone. Default false to not show multi availability zone.
    outputFile String
    File name where to save data source results (after running pulumi up).
    zoneId String
    The Zone to launch the DB instance.

    getInstanceEngines Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Ids List<string>
    A list of engines.
    InstanceEngines List<Pulumi.AliCloud.Rds.Outputs.GetInstanceEnginesInstanceEngine>
    A list of Rds available resource. Each element contains the following attributes:
    Category string
    DB Instance category.
    DbInstanceStorageType string
    Engine string
    Database type.
    EngineVersion string
    DB Instance version.
    InstanceChargeType string
    MultiZone bool
    OutputFile string
    ZoneId string
    Id string
    The provider-assigned unique ID for this managed resource.
    Ids []string
    A list of engines.
    InstanceEngines []GetInstanceEnginesInstanceEngine
    A list of Rds available resource. Each element contains the following attributes:
    Category string
    DB Instance category.
    DbInstanceStorageType string
    Engine string
    Database type.
    EngineVersion string
    DB Instance version.
    InstanceChargeType string
    MultiZone bool
    OutputFile string
    ZoneId string
    id String
    The provider-assigned unique ID for this managed resource.
    ids List<String>
    A list of engines.
    instanceEngines List<GetInstanceEnginesInstanceEngine>
    A list of Rds available resource. Each element contains the following attributes:
    category String
    DB Instance category.
    dbInstanceStorageType String
    engine String
    Database type.
    engineVersion String
    DB Instance version.
    instanceChargeType String
    multiZone Boolean
    outputFile String
    zoneId String
    id string
    The provider-assigned unique ID for this managed resource.
    ids string[]
    A list of engines.
    instanceEngines GetInstanceEnginesInstanceEngine[]
    A list of Rds available resource. Each element contains the following attributes:
    category string
    DB Instance category.
    dbInstanceStorageType string
    engine string
    Database type.
    engineVersion string
    DB Instance version.
    instanceChargeType string
    multiZone boolean
    outputFile string
    zoneId string
    id str
    The provider-assigned unique ID for this managed resource.
    ids Sequence[str]
    A list of engines.
    instance_engines Sequence[GetInstanceEnginesInstanceEngine]
    A list of Rds available resource. Each element contains the following attributes:
    category str
    DB Instance category.
    db_instance_storage_type str
    engine str
    Database type.
    engine_version str
    DB Instance version.
    instance_charge_type str
    multi_zone bool
    output_file str
    zone_id str
    id String
    The provider-assigned unique ID for this managed resource.
    ids List<String>
    A list of engines.
    instanceEngines List<Property Map>
    A list of Rds available resource. Each element contains the following attributes:
    category String
    DB Instance category.
    dbInstanceStorageType String
    engine String
    Database type.
    engineVersion String
    DB Instance version.
    instanceChargeType String
    multiZone Boolean
    outputFile String
    zoneId String

    Supporting Types

    GetInstanceEnginesInstanceEngine

    Category string
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    Engine string
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    EngineVersion string
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    ZoneIds List<Pulumi.AliCloud.Rds.Inputs.GetInstanceEnginesInstanceEngineZoneId>
    A list of Zone to launch the DB instance.
    Category string
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    Engine string
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    EngineVersion string
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    ZoneIds []GetInstanceEnginesInstanceEngineZoneId
    A list of Zone to launch the DB instance.
    category String
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    engine String
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    engineVersion String
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    zoneIds List<GetInstanceEnginesInstanceEngineZoneId>
    A list of Zone to launch the DB instance.
    category string
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    engine string
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    engineVersion string
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    zoneIds GetInstanceEnginesInstanceEngineZoneId[]
    A list of Zone to launch the DB instance.
    category str
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    engine str
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    engine_version str
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    zone_ids Sequence[GetInstanceEnginesInstanceEngineZoneId]
    A list of Zone to launch the DB instance.
    category String
    DB Instance category. the value like [Basic, HighAvailability, Finance, AlwaysOn], detail info.
    engine String
    Database type. Valid values: "MySQL", "SQLServer", "PostgreSQL", "MariaDB". If not set, it will match all of engines.
    engineVersion String
    Database version required by the user. Value options can refer to the latest docs detail info EngineVersion.
    zoneIds List<Property Map>
    A list of Zone to launch the DB instance.

    GetInstanceEnginesInstanceEngineZoneId

    Id string
    The Zone to launch the DB instance
    SubZoneIds List<string>
    A list of sub zone ids which in the id - e.g If id is cn-beijing-MAZ5(a,b), sub_zone_ids will be ["cn-beijing-a", "cn-beijing-b"].
    Id string
    The Zone to launch the DB instance
    SubZoneIds []string
    A list of sub zone ids which in the id - e.g If id is cn-beijing-MAZ5(a,b), sub_zone_ids will be ["cn-beijing-a", "cn-beijing-b"].
    id String
    The Zone to launch the DB instance
    subZoneIds List<String>
    A list of sub zone ids which in the id - e.g If id is cn-beijing-MAZ5(a,b), sub_zone_ids will be ["cn-beijing-a", "cn-beijing-b"].
    id string
    The Zone to launch the DB instance
    subZoneIds string[]
    A list of sub zone ids which in the id - e.g If id is cn-beijing-MAZ5(a,b), sub_zone_ids will be ["cn-beijing-a", "cn-beijing-b"].
    id str
    The Zone to launch the DB instance
    sub_zone_ids Sequence[str]
    A list of sub zone ids which in the id - e.g If id is cn-beijing-MAZ5(a,b), sub_zone_ids will be ["cn-beijing-a", "cn-beijing-b"].
    id String
    The Zone to launch the DB instance
    subZoneIds List<String>
    A list of sub zone ids which in the id - e.g If id is cn-beijing-MAZ5(a,b), sub_zone_ids will be ["cn-beijing-a", "cn-beijing-b"].

    Package Details

    Repository
    Alibaba Cloud pulumi/pulumi-alicloud
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the alicloud Terraform Provider.
    alicloud logo
    Alibaba Cloud v3.66.0 published on Friday, Nov 15, 2024 by Pulumi