Alibaba Cloud

Pulumi Official
Package maintained by Pulumi
v3.22.0 published on Monday, Jun 27, 2022 by Pulumi

Instance

Distributed Relational Database Service (DRDS) is a lightweight (stateless), flexible, stable, and efficient middleware product independently developed by Alibaba Group to resolve scalability issues with single-host relational databases. With its compatibility with MySQL protocols and syntaxes, DRDS enables database/table sharding, smooth scaling, configuration upgrade/downgrade, transparent read/write splitting, and distributed transactions, providing O&M capabilities for distributed databases throughout their entire lifecycle.

For information about DRDS and how to use it, see What is DRDS.

NOTE: At present, DRDS instance only can be supported in the regions: cn-shenzhen, cn-beijing, cn-hangzhou, cn-hongkong, cn-qingdao, ap-southeast-1.

NOTE: Currently, this resource only support Domestic Site Account.

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var @default = new AliCloud.Drds.Instance("default", new AliCloud.Drds.InstanceArgs
        {
            Description = "drds instance",
            InstanceChargeType = "PostPaid",
            InstanceSeries = "drds.sn1.4c8g",
            Specification = "drds.sn1.4c8g.8C16G",
            VswitchId = "vsw-bp1jlu3swk8rq2yoi40ey",
            ZoneId = "cn-hangzhou-e",
        });
    }

}
package main

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

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := drds.NewInstance(ctx, "default", &drds.InstanceArgs{
			Description:        pulumi.String("drds instance"),
			InstanceChargeType: pulumi.String("PostPaid"),
			InstanceSeries:     pulumi.String("drds.sn1.4c8g"),
			Specification:      pulumi.String("drds.sn1.4c8g.8C16G"),
			VswitchId:          pulumi.String("vsw-bp1jlu3swk8rq2yoi40ey"),
			ZoneId:             pulumi.String("cn-hangzhou-e"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_alicloud as alicloud

default = alicloud.drds.Instance("default",
    description="drds instance",
    instance_charge_type="PostPaid",
    instance_series="drds.sn1.4c8g",
    specification="drds.sn1.4c8g.8C16G",
    vswitch_id="vsw-bp1jlu3swk8rq2yoi40ey",
    zone_id="cn-hangzhou-e")
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const defaultInstance = new alicloud.drds.Instance("default", {
    description: "drds instance",
    instanceChargeType: "PostPaid",
    instanceSeries: "drds.sn1.4c8g",
    specification: "drds.sn1.4c8g.8C16G",
    vswitchId: "vsw-bp1jlu3swk8rq2yoi40ey",
    zoneId: "cn-hangzhou-e",
});

Coming soon!

Create a Instance Resource

new Instance(name: string, args: InstanceArgs, opts?: CustomResourceOptions);
@overload
def Instance(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             description: Optional[str] = None,
             instance_charge_type: Optional[str] = None,
             instance_series: Optional[str] = None,
             specification: Optional[str] = None,
             vswitch_id: Optional[str] = None,
             zone_id: Optional[str] = None)
@overload
def Instance(resource_name: str,
             args: InstanceArgs,
             opts: Optional[ResourceOptions] = None)
func NewInstance(ctx *Context, name string, args InstanceArgs, opts ...ResourceOption) (*Instance, error)
public Instance(string name, InstanceArgs args, CustomResourceOptions? opts = null)
public Instance(String name, InstanceArgs args)
public Instance(String name, InstanceArgs args, CustomResourceOptions options)
type: alicloud:drds:Instance
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args InstanceArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args InstanceArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args InstanceArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args InstanceArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args InstanceArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

Instance Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The Instance resource accepts the following input properties:

Description string

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

InstanceSeries string

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
Specification string

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
VswitchId string

The VSwitch ID to launch in.

ZoneId string

The Zone to launch the DRDS instance.

InstanceChargeType string

Valid values are PrePaid, PostPaid, Default to PostPaid.

Description string

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

InstanceSeries string

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
Specification string

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
VswitchId string

The VSwitch ID to launch in.

ZoneId string

The Zone to launch the DRDS instance.

InstanceChargeType string

Valid values are PrePaid, PostPaid, Default to PostPaid.

description String

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

instanceSeries String

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
specification String

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
vswitchId String

The VSwitch ID to launch in.

zoneId String

The Zone to launch the DRDS instance.

instanceChargeType String

Valid values are PrePaid, PostPaid, Default to PostPaid.

description string

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

instanceSeries string

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
specification string

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
vswitchId string

The VSwitch ID to launch in.

zoneId string

The Zone to launch the DRDS instance.

instanceChargeType string

Valid values are PrePaid, PostPaid, Default to PostPaid.

description str

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

instance_series str

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
specification str

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
vswitch_id str

The VSwitch ID to launch in.

zone_id str

The Zone to launch the DRDS instance.

instance_charge_type str

Valid values are PrePaid, PostPaid, Default to PostPaid.

description String

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

instanceSeries String

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
specification String

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
vswitchId String

The VSwitch ID to launch in.

zoneId String

The Zone to launch the DRDS instance.

instanceChargeType String

Valid values are PrePaid, PostPaid, Default to PostPaid.

Outputs

All input properties are implicitly available as output properties. Additionally, the Instance resource produces the following output properties:

Id string

The provider-assigned unique ID for this managed resource.

Id string

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

id string

The provider-assigned unique ID for this managed resource.

id str

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

Look up an Existing Instance Resource

Get an existing Instance resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: InstanceState, opts?: CustomResourceOptions): Instance
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        description: Optional[str] = None,
        instance_charge_type: Optional[str] = None,
        instance_series: Optional[str] = None,
        specification: Optional[str] = None,
        vswitch_id: Optional[str] = None,
        zone_id: Optional[str] = None) -> Instance
func GetInstance(ctx *Context, name string, id IDInput, state *InstanceState, opts ...ResourceOption) (*Instance, error)
public static Instance Get(string name, Input<string> id, InstanceState? state, CustomResourceOptions? opts = null)
public static Instance get(String name, Output<String> id, InstanceState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
Description string

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

InstanceChargeType string

Valid values are PrePaid, PostPaid, Default to PostPaid.

InstanceSeries string

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
Specification string

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
VswitchId string

The VSwitch ID to launch in.

ZoneId string

The Zone to launch the DRDS instance.

Description string

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

InstanceChargeType string

Valid values are PrePaid, PostPaid, Default to PostPaid.

InstanceSeries string

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
Specification string

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
VswitchId string

The VSwitch ID to launch in.

ZoneId string

The Zone to launch the DRDS instance.

description String

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

instanceChargeType String

Valid values are PrePaid, PostPaid, Default to PostPaid.

instanceSeries String

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
specification String

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
vswitchId String

The VSwitch ID to launch in.

zoneId String

The Zone to launch the DRDS instance.

description string

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

instanceChargeType string

Valid values are PrePaid, PostPaid, Default to PostPaid.

instanceSeries string

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
specification string

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
vswitchId string

The VSwitch ID to launch in.

zoneId string

The Zone to launch the DRDS instance.

description str

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

instance_charge_type str

Valid values are PrePaid, PostPaid, Default to PostPaid.

instance_series str

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
specification str

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
vswitch_id str

The VSwitch ID to launch in.

zone_id str

The Zone to launch the DRDS instance.

description String

Description of the DRDS instance, This description can have a string of 2 to 256 characters.

instanceChargeType String

Valid values are PrePaid, PostPaid, Default to PostPaid.

instanceSeries String

The parameter of the instance series. NOTE: drds.sn1.4c8g,drds.sn1.8c16g,drds.sn1.16c32g,drds.sn1.32c64g are no longer supported. Valid values:

  • drds.sn2.4c16g Starter Edition.
  • drds.sn2.8c32g Standard Edition.
  • drds.sn2.16c64g Enterprise Edition.
specification String

User-defined DRDS instance specification. Value range:

  • drds.sn1.4c8g for DRDS instance Starter version;
  • value range : drds.sn1.4c8g.8c16g, drds.sn1.4c8g.16c32g, drds.sn1.4c8g.32c64g, drds.sn1.4c8g.64c128g
  • drds.sn1.8c16g for DRDS instance Standard edition;
  • value range : drds.sn1.8c16g.16c32g, drds.sn1.8c16g.32c64g, drds.sn1.8c16g.64c128g
  • drds.sn1.16c32g for DRDS instance Enterprise Edition;
  • value range : drds.sn1.16c32g.32c64g, drds.sn1.16c32g.64c128g
  • drds.sn1.32c64g for DRDS instance Extreme Edition;
  • value range : drds.sn1.32c64g.128c256g
vswitchId String

The VSwitch ID to launch in.

zoneId String

The Zone to launch the DRDS instance.

Import

Distributed Relational Database Service (DRDS) can be imported using the id, e.g.

 $ pulumi import alicloud:drds/instance:Instance example drds-abc123456

Package Details

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

This Pulumi package is based on the alicloud Terraform Provider.