tencentcloud.SqlserverReadonlyInstance
Explore with Pulumi AI
Provides a SQL Server instance resource to create read-only database instances.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as tencentcloud from "@pulumi/tencentcloud";
const zones = tencentcloud.getAvailabilityZonesByProduct({
    product: "sqlserver",
});
const vpc = new tencentcloud.Vpc("vpc", {cidrBlock: "10.0.0.0/16"});
const subnet = new tencentcloud.Subnet("subnet", {
    availabilityZone: zones.then(zones => zones.zones?.[4]?.name),
    vpcId: vpc.vpcId,
    cidrBlock: "10.0.0.0/16",
    isMulticast: false,
});
const securityGroup = new tencentcloud.SecurityGroup("securityGroup", {description: "desc."});
const exampleSqlserverInstance = new tencentcloud.SqlserverInstance("exampleSqlserverInstance", {
    availabilityZone: zones.then(zones => zones.zones?.[4]?.name),
    multiZones: true,
    chargeType: "POSTPAID_BY_HOUR",
    engineVersion: "2019",
    vpcId: vpc.vpcId,
    subnetId: subnet.subnetId,
    projectId: 0,
    memory: 16,
    storage: 20,
    securityGroups: [securityGroup.securityGroupId],
});
const exampleSqlserverReadonlyInstance = new tencentcloud.SqlserverReadonlyInstance("exampleSqlserverReadonlyInstance", {
    availabilityZone: zones.then(zones => zones.zones?.[4]?.name),
    chargeType: "POSTPAID_BY_HOUR",
    vpcId: vpc.vpcId,
    subnetId: subnet.subnetId,
    memory: 4,
    storage: 20,
    masterInstanceId: exampleSqlserverInstance.sqlserverInstanceId,
    readonlyGroupType: 1,
    forceUpgrade: true,
    tags: {
        CreateBy: "Terraform",
    },
});
import pulumi
import pulumi_tencentcloud as tencentcloud
zones = tencentcloud.get_availability_zones_by_product(product="sqlserver")
vpc = tencentcloud.Vpc("vpc", cidr_block="10.0.0.0/16")
subnet = tencentcloud.Subnet("subnet",
    availability_zone=zones.zones[4].name,
    vpc_id=vpc.vpc_id,
    cidr_block="10.0.0.0/16",
    is_multicast=False)
security_group = tencentcloud.SecurityGroup("securityGroup", description="desc.")
example_sqlserver_instance = tencentcloud.SqlserverInstance("exampleSqlserverInstance",
    availability_zone=zones.zones[4].name,
    multi_zones=True,
    charge_type="POSTPAID_BY_HOUR",
    engine_version="2019",
    vpc_id=vpc.vpc_id,
    subnet_id=subnet.subnet_id,
    project_id=0,
    memory=16,
    storage=20,
    security_groups=[security_group.security_group_id])
example_sqlserver_readonly_instance = tencentcloud.SqlserverReadonlyInstance("exampleSqlserverReadonlyInstance",
    availability_zone=zones.zones[4].name,
    charge_type="POSTPAID_BY_HOUR",
    vpc_id=vpc.vpc_id,
    subnet_id=subnet.subnet_id,
    memory=4,
    storage=20,
    master_instance_id=example_sqlserver_instance.sqlserver_instance_id,
    readonly_group_type=1,
    force_upgrade=True,
    tags={
        "CreateBy": "Terraform",
    })
package main
import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/tencentcloud/tencentcloud"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		zones, err := tencentcloud.GetAvailabilityZonesByProduct(ctx, &tencentcloud.GetAvailabilityZonesByProductArgs{
			Product: "sqlserver",
		}, nil)
		if err != nil {
			return err
		}
		vpc, err := tencentcloud.NewVpc(ctx, "vpc", &tencentcloud.VpcArgs{
			CidrBlock: pulumi.String("10.0.0.0/16"),
		})
		if err != nil {
			return err
		}
		subnet, err := tencentcloud.NewSubnet(ctx, "subnet", &tencentcloud.SubnetArgs{
			AvailabilityZone: pulumi.String(zones.Zones[4].Name),
			VpcId:            vpc.VpcId,
			CidrBlock:        pulumi.String("10.0.0.0/16"),
			IsMulticast:      pulumi.Bool(false),
		})
		if err != nil {
			return err
		}
		securityGroup, err := tencentcloud.NewSecurityGroup(ctx, "securityGroup", &tencentcloud.SecurityGroupArgs{
			Description: pulumi.String("desc."),
		})
		if err != nil {
			return err
		}
		exampleSqlserverInstance, err := tencentcloud.NewSqlserverInstance(ctx, "exampleSqlserverInstance", &tencentcloud.SqlserverInstanceArgs{
			AvailabilityZone: pulumi.String(zones.Zones[4].Name),
			MultiZones:       pulumi.Bool(true),
			ChargeType:       pulumi.String("POSTPAID_BY_HOUR"),
			EngineVersion:    pulumi.String("2019"),
			VpcId:            vpc.VpcId,
			SubnetId:         subnet.SubnetId,
			ProjectId:        pulumi.Float64(0),
			Memory:           pulumi.Float64(16),
			Storage:          pulumi.Float64(20),
			SecurityGroups: pulumi.StringArray{
				securityGroup.SecurityGroupId,
			},
		})
		if err != nil {
			return err
		}
		_, err = tencentcloud.NewSqlserverReadonlyInstance(ctx, "exampleSqlserverReadonlyInstance", &tencentcloud.SqlserverReadonlyInstanceArgs{
			AvailabilityZone:  pulumi.String(zones.Zones[4].Name),
			ChargeType:        pulumi.String("POSTPAID_BY_HOUR"),
			VpcId:             vpc.VpcId,
			SubnetId:          subnet.SubnetId,
			Memory:            pulumi.Float64(4),
			Storage:           pulumi.Float64(20),
			MasterInstanceId:  exampleSqlserverInstance.SqlserverInstanceId,
			ReadonlyGroupType: pulumi.Float64(1),
			ForceUpgrade:      pulumi.Bool(true),
			Tags: pulumi.StringMap{
				"CreateBy": pulumi.String("Terraform"),
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Tencentcloud = Pulumi.Tencentcloud;
return await Deployment.RunAsync(() => 
{
    var zones = Tencentcloud.GetAvailabilityZonesByProduct.Invoke(new()
    {
        Product = "sqlserver",
    });
    var vpc = new Tencentcloud.Vpc("vpc", new()
    {
        CidrBlock = "10.0.0.0/16",
    });
    var subnet = new Tencentcloud.Subnet("subnet", new()
    {
        AvailabilityZone = zones.Apply(getAvailabilityZonesByProductResult => getAvailabilityZonesByProductResult.Zones[4]?.Name),
        VpcId = vpc.VpcId,
        CidrBlock = "10.0.0.0/16",
        IsMulticast = false,
    });
    var securityGroup = new Tencentcloud.SecurityGroup("securityGroup", new()
    {
        Description = "desc.",
    });
    var exampleSqlserverInstance = new Tencentcloud.SqlserverInstance("exampleSqlserverInstance", new()
    {
        AvailabilityZone = zones.Apply(getAvailabilityZonesByProductResult => getAvailabilityZonesByProductResult.Zones[4]?.Name),
        MultiZones = true,
        ChargeType = "POSTPAID_BY_HOUR",
        EngineVersion = "2019",
        VpcId = vpc.VpcId,
        SubnetId = subnet.SubnetId,
        ProjectId = 0,
        Memory = 16,
        Storage = 20,
        SecurityGroups = new[]
        {
            securityGroup.SecurityGroupId,
        },
    });
    var exampleSqlserverReadonlyInstance = new Tencentcloud.SqlserverReadonlyInstance("exampleSqlserverReadonlyInstance", new()
    {
        AvailabilityZone = zones.Apply(getAvailabilityZonesByProductResult => getAvailabilityZonesByProductResult.Zones[4]?.Name),
        ChargeType = "POSTPAID_BY_HOUR",
        VpcId = vpc.VpcId,
        SubnetId = subnet.SubnetId,
        Memory = 4,
        Storage = 20,
        MasterInstanceId = exampleSqlserverInstance.SqlserverInstanceId,
        ReadonlyGroupType = 1,
        ForceUpgrade = true,
        Tags = 
        {
            { "CreateBy", "Terraform" },
        },
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.tencentcloud.TencentcloudFunctions;
import com.pulumi.tencentcloud.inputs.GetAvailabilityZonesByProductArgs;
import com.pulumi.tencentcloud.Vpc;
import com.pulumi.tencentcloud.VpcArgs;
import com.pulumi.tencentcloud.Subnet;
import com.pulumi.tencentcloud.SubnetArgs;
import com.pulumi.tencentcloud.SecurityGroup;
import com.pulumi.tencentcloud.SecurityGroupArgs;
import com.pulumi.tencentcloud.SqlserverInstance;
import com.pulumi.tencentcloud.SqlserverInstanceArgs;
import com.pulumi.tencentcloud.SqlserverReadonlyInstance;
import com.pulumi.tencentcloud.SqlserverReadonlyInstanceArgs;
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 zones = TencentcloudFunctions.getAvailabilityZonesByProduct(GetAvailabilityZonesByProductArgs.builder()
            .product("sqlserver")
            .build());
        var vpc = new Vpc("vpc", VpcArgs.builder()
            .cidrBlock("10.0.0.0/16")
            .build());
        var subnet = new Subnet("subnet", SubnetArgs.builder()
            .availabilityZone(zones.applyValue(getAvailabilityZonesByProductResult -> getAvailabilityZonesByProductResult.zones()[4].name()))
            .vpcId(vpc.vpcId())
            .cidrBlock("10.0.0.0/16")
            .isMulticast(false)
            .build());
        var securityGroup = new SecurityGroup("securityGroup", SecurityGroupArgs.builder()
            .description("desc.")
            .build());
        var exampleSqlserverInstance = new SqlserverInstance("exampleSqlserverInstance", SqlserverInstanceArgs.builder()
            .availabilityZone(zones.applyValue(getAvailabilityZonesByProductResult -> getAvailabilityZonesByProductResult.zones()[4].name()))
            .multiZones(true)
            .chargeType("POSTPAID_BY_HOUR")
            .engineVersion("2019")
            .vpcId(vpc.vpcId())
            .subnetId(subnet.subnetId())
            .projectId(0)
            .memory(16)
            .storage(20)
            .securityGroups(securityGroup.securityGroupId())
            .build());
        var exampleSqlserverReadonlyInstance = new SqlserverReadonlyInstance("exampleSqlserverReadonlyInstance", SqlserverReadonlyInstanceArgs.builder()
            .availabilityZone(zones.applyValue(getAvailabilityZonesByProductResult -> getAvailabilityZonesByProductResult.zones()[4].name()))
            .chargeType("POSTPAID_BY_HOUR")
            .vpcId(vpc.vpcId())
            .subnetId(subnet.subnetId())
            .memory(4)
            .storage(20)
            .masterInstanceId(exampleSqlserverInstance.sqlserverInstanceId())
            .readonlyGroupType(1)
            .forceUpgrade(true)
            .tags(Map.of("CreateBy", "Terraform"))
            .build());
    }
}
resources:
  vpc:
    type: tencentcloud:Vpc
    properties:
      cidrBlock: 10.0.0.0/16
  subnet:
    type: tencentcloud:Subnet
    properties:
      availabilityZone: ${zones.zones[4].name}
      vpcId: ${vpc.vpcId}
      cidrBlock: 10.0.0.0/16
      isMulticast: false
  securityGroup:
    type: tencentcloud:SecurityGroup
    properties:
      description: desc.
  exampleSqlserverInstance:
    type: tencentcloud:SqlserverInstance
    properties:
      availabilityZone: ${zones.zones[4].name}
      multiZones: true
      chargeType: POSTPAID_BY_HOUR
      engineVersion: '2019'
      vpcId: ${vpc.vpcId}
      subnetId: ${subnet.subnetId}
      projectId: 0
      memory: 16
      storage: 20
      securityGroups:
        - ${securityGroup.securityGroupId}
  exampleSqlserverReadonlyInstance:
    type: tencentcloud:SqlserverReadonlyInstance
    properties:
      availabilityZone: ${zones.zones[4].name}
      chargeType: POSTPAID_BY_HOUR
      vpcId: ${vpc.vpcId}
      subnetId: ${subnet.subnetId}
      memory: 4
      storage: 20
      masterInstanceId: ${exampleSqlserverInstance.sqlserverInstanceId}
      readonlyGroupType: 1
      forceUpgrade: true
      tags:
        CreateBy: Terraform
variables:
  zones:
    fn::invoke:
      function: tencentcloud:getAvailabilityZonesByProduct
      arguments:
        product: sqlserver
Create SqlserverReadonlyInstance Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new SqlserverReadonlyInstance(name: string, args: SqlserverReadonlyInstanceArgs, opts?: CustomResourceOptions);@overload
def SqlserverReadonlyInstance(resource_name: str,
                              args: SqlserverReadonlyInstanceArgs,
                              opts: Optional[ResourceOptions] = None)
@overload
def SqlserverReadonlyInstance(resource_name: str,
                              opts: Optional[ResourceOptions] = None,
                              readonly_group_type: Optional[float] = None,
                              master_instance_id: Optional[str] = None,
                              storage: Optional[float] = None,
                              memory: Optional[float] = None,
                              name: Optional[str] = None,
                              readonly_groups_min_in_group: Optional[float] = None,
                              auto_voucher: Optional[float] = None,
                              readonly_groups_max_delay_time: Optional[float] = None,
                              readonly_groups_is_offline_delay: Optional[float] = None,
                              readonly_group_name: Optional[str] = None,
                              availability_zone: Optional[str] = None,
                              readonly_group_id: Optional[str] = None,
                              period: Optional[float] = None,
                              force_upgrade: Optional[bool] = None,
                              security_groups: Optional[Sequence[str]] = None,
                              sqlserver_readonly_instance_id: Optional[str] = None,
                              charge_type: Optional[str] = None,
                              subnet_id: Optional[str] = None,
                              tags: Optional[Mapping[str, str]] = None,
                              time_zone: Optional[str] = None,
                              voucher_ids: Optional[Sequence[str]] = None,
                              vpc_id: Optional[str] = None,
                              wait_switch: Optional[float] = None)func NewSqlserverReadonlyInstance(ctx *Context, name string, args SqlserverReadonlyInstanceArgs, opts ...ResourceOption) (*SqlserverReadonlyInstance, error)public SqlserverReadonlyInstance(string name, SqlserverReadonlyInstanceArgs args, CustomResourceOptions? opts = null)
public SqlserverReadonlyInstance(String name, SqlserverReadonlyInstanceArgs args)
public SqlserverReadonlyInstance(String name, SqlserverReadonlyInstanceArgs args, CustomResourceOptions options)
type: tencentcloud:SqlserverReadonlyInstance
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args SqlserverReadonlyInstanceArgs
- 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 SqlserverReadonlyInstanceArgs
- 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 SqlserverReadonlyInstanceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SqlserverReadonlyInstanceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SqlserverReadonlyInstanceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
SqlserverReadonlyInstance Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The SqlserverReadonlyInstance resource accepts the following input properties:
- MasterInstance stringId 
- Indicates the master instance ID of recovery instances.
- Memory double
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- ReadonlyGroup doubleType 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- Storage double
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- AutoVoucher double
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- AvailabilityZone string
- Availability zone.
- ChargeType string
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- ForceUpgrade bool
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- Name string
- Name of the SQL Server instance.
- Period double
- Purchase instance period in month. The value does not exceed 48.
- ReadonlyGroup stringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- ReadonlyGroup stringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- ReadonlyGroups doubleIs Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- ReadonlyGroups doubleMax Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- ReadonlyGroups doubleMin In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- SecurityGroups List<string>
- Security group bound to the instance.
- SqlserverReadonly stringInstance Id 
- ID of the resource.
- SubnetId string
- ID of subnet.
- Dictionary<string, string>
- The tags of the SQL Server.
- TimeZone string
- System time zone, default: China Standard Time.
- VoucherIds List<string>
- An array of voucher IDs, currently only one can be used for a single order.
- VpcId string
- ID of VPC.
- WaitSwitch double
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- MasterInstance stringId 
- Indicates the master instance ID of recovery instances.
- Memory float64
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- ReadonlyGroup float64Type 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- Storage float64
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- AutoVoucher float64
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- AvailabilityZone string
- Availability zone.
- ChargeType string
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- ForceUpgrade bool
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- Name string
- Name of the SQL Server instance.
- Period float64
- Purchase instance period in month. The value does not exceed 48.
- ReadonlyGroup stringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- ReadonlyGroup stringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- ReadonlyGroups float64Is Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- ReadonlyGroups float64Max Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- ReadonlyGroups float64Min In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- SecurityGroups []string
- Security group bound to the instance.
- SqlserverReadonly stringInstance Id 
- ID of the resource.
- SubnetId string
- ID of subnet.
- map[string]string
- The tags of the SQL Server.
- TimeZone string
- System time zone, default: China Standard Time.
- VoucherIds []string
- An array of voucher IDs, currently only one can be used for a single order.
- VpcId string
- ID of VPC.
- WaitSwitch float64
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- masterInstance StringId 
- Indicates the master instance ID of recovery instances.
- memory Double
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- readonlyGroup DoubleType 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- storage Double
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- autoVoucher Double
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- availabilityZone String
- Availability zone.
- chargeType String
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- forceUpgrade Boolean
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- name String
- Name of the SQL Server instance.
- period Double
- Purchase instance period in month. The value does not exceed 48.
- readonlyGroup StringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- readonlyGroup StringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- readonlyGroups DoubleIs Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- readonlyGroups DoubleMax Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- readonlyGroups DoubleMin In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- securityGroups List<String>
- Security group bound to the instance.
- sqlserverReadonly StringInstance Id 
- ID of the resource.
- subnetId String
- ID of subnet.
- Map<String,String>
- The tags of the SQL Server.
- timeZone String
- System time zone, default: China Standard Time.
- voucherIds List<String>
- An array of voucher IDs, currently only one can be used for a single order.
- vpcId String
- ID of VPC.
- waitSwitch Double
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- masterInstance stringId 
- Indicates the master instance ID of recovery instances.
- memory number
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- readonlyGroup numberType 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- storage number
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- autoVoucher number
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- availabilityZone string
- Availability zone.
- chargeType string
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- forceUpgrade boolean
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- name string
- Name of the SQL Server instance.
- period number
- Purchase instance period in month. The value does not exceed 48.
- readonlyGroup stringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- readonlyGroup stringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- readonlyGroups numberIs Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- readonlyGroups numberMax Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- readonlyGroups numberMin In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- securityGroups string[]
- Security group bound to the instance.
- sqlserverReadonly stringInstance Id 
- ID of the resource.
- subnetId string
- ID of subnet.
- {[key: string]: string}
- The tags of the SQL Server.
- timeZone string
- System time zone, default: China Standard Time.
- voucherIds string[]
- An array of voucher IDs, currently only one can be used for a single order.
- vpcId string
- ID of VPC.
- waitSwitch number
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- master_instance_ strid 
- Indicates the master instance ID of recovery instances.
- memory float
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- readonly_group_ floattype 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- storage float
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- auto_voucher float
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- availability_zone str
- Availability zone.
- charge_type str
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- force_upgrade bool
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- name str
- Name of the SQL Server instance.
- period float
- Purchase instance period in month. The value does not exceed 48.
- readonly_group_ strid 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- readonly_group_ strname 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- readonly_groups_ floatis_ offline_ delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- readonly_groups_ floatmax_ delay_ time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- readonly_groups_ floatmin_ in_ group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- security_groups Sequence[str]
- Security group bound to the instance.
- sqlserver_readonly_ strinstance_ id 
- ID of the resource.
- subnet_id str
- ID of subnet.
- Mapping[str, str]
- The tags of the SQL Server.
- time_zone str
- System time zone, default: China Standard Time.
- voucher_ids Sequence[str]
- An array of voucher IDs, currently only one can be used for a single order.
- vpc_id str
- ID of VPC.
- wait_switch float
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- masterInstance StringId 
- Indicates the master instance ID of recovery instances.
- memory Number
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- readonlyGroup NumberType 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- storage Number
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- autoVoucher Number
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- availabilityZone String
- Availability zone.
- chargeType String
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- forceUpgrade Boolean
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- name String
- Name of the SQL Server instance.
- period Number
- Purchase instance period in month. The value does not exceed 48.
- readonlyGroup StringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- readonlyGroup StringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- readonlyGroups NumberIs Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- readonlyGroups NumberMax Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- readonlyGroups NumberMin In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- securityGroups List<String>
- Security group bound to the instance.
- sqlserverReadonly StringInstance Id 
- ID of the resource.
- subnetId String
- ID of subnet.
- Map<String>
- The tags of the SQL Server.
- timeZone String
- System time zone, default: China Standard Time.
- voucherIds List<String>
- An array of voucher IDs, currently only one can be used for a single order.
- vpcId String
- ID of VPC.
- waitSwitch Number
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
Outputs
All input properties are implicitly available as output properties. Additionally, the SqlserverReadonlyInstance resource produces the following output properties:
- CreateTime string
- Create time of the SQL Server instance.
- DnsPod stringDomain 
- Internet address domain name.
- EngineVersion string
- Version of the SQL Server database engine.
- HaType string
- Instance type.
- Id string
- The provider-assigned unique ID for this managed resource.
- ProjectId double
- Project ID.
- RoFlag string
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- Status double
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- TgwWan doubleVport 
- External port number.
- Vip string
- IP for private access.
- Vport double
- Port for private access.
- CreateTime string
- Create time of the SQL Server instance.
- DnsPod stringDomain 
- Internet address domain name.
- EngineVersion string
- Version of the SQL Server database engine.
- HaType string
- Instance type.
- Id string
- The provider-assigned unique ID for this managed resource.
- ProjectId float64
- Project ID.
- RoFlag string
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- Status float64
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- TgwWan float64Vport 
- External port number.
- Vip string
- IP for private access.
- Vport float64
- Port for private access.
- createTime String
- Create time of the SQL Server instance.
- dnsPod StringDomain 
- Internet address domain name.
- engineVersion String
- Version of the SQL Server database engine.
- haType String
- Instance type.
- id String
- The provider-assigned unique ID for this managed resource.
- projectId Double
- Project ID.
- roFlag String
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- status Double
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- tgwWan DoubleVport 
- External port number.
- vip String
- IP for private access.
- vport Double
- Port for private access.
- createTime string
- Create time of the SQL Server instance.
- dnsPod stringDomain 
- Internet address domain name.
- engineVersion string
- Version of the SQL Server database engine.
- haType string
- Instance type.
- id string
- The provider-assigned unique ID for this managed resource.
- projectId number
- Project ID.
- roFlag string
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- status number
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- tgwWan numberVport 
- External port number.
- vip string
- IP for private access.
- vport number
- Port for private access.
- create_time str
- Create time of the SQL Server instance.
- dns_pod_ strdomain 
- Internet address domain name.
- engine_version str
- Version of the SQL Server database engine.
- ha_type str
- Instance type.
- id str
- The provider-assigned unique ID for this managed resource.
- project_id float
- Project ID.
- ro_flag str
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- status float
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- tgw_wan_ floatvport 
- External port number.
- vip str
- IP for private access.
- vport float
- Port for private access.
- createTime String
- Create time of the SQL Server instance.
- dnsPod StringDomain 
- Internet address domain name.
- engineVersion String
- Version of the SQL Server database engine.
- haType String
- Instance type.
- id String
- The provider-assigned unique ID for this managed resource.
- projectId Number
- Project ID.
- roFlag String
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- status Number
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- tgwWan NumberVport 
- External port number.
- vip String
- IP for private access.
- vport Number
- Port for private access.
Look up Existing SqlserverReadonlyInstance Resource
Get an existing SqlserverReadonlyInstance 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?: SqlserverReadonlyInstanceState, opts?: CustomResourceOptions): SqlserverReadonlyInstance@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        auto_voucher: Optional[float] = None,
        availability_zone: Optional[str] = None,
        charge_type: Optional[str] = None,
        create_time: Optional[str] = None,
        dns_pod_domain: Optional[str] = None,
        engine_version: Optional[str] = None,
        force_upgrade: Optional[bool] = None,
        ha_type: Optional[str] = None,
        master_instance_id: Optional[str] = None,
        memory: Optional[float] = None,
        name: Optional[str] = None,
        period: Optional[float] = None,
        project_id: Optional[float] = None,
        readonly_group_id: Optional[str] = None,
        readonly_group_name: Optional[str] = None,
        readonly_group_type: Optional[float] = None,
        readonly_groups_is_offline_delay: Optional[float] = None,
        readonly_groups_max_delay_time: Optional[float] = None,
        readonly_groups_min_in_group: Optional[float] = None,
        ro_flag: Optional[str] = None,
        security_groups: Optional[Sequence[str]] = None,
        sqlserver_readonly_instance_id: Optional[str] = None,
        status: Optional[float] = None,
        storage: Optional[float] = None,
        subnet_id: Optional[str] = None,
        tags: Optional[Mapping[str, str]] = None,
        tgw_wan_vport: Optional[float] = None,
        time_zone: Optional[str] = None,
        vip: Optional[str] = None,
        voucher_ids: Optional[Sequence[str]] = None,
        vpc_id: Optional[str] = None,
        vport: Optional[float] = None,
        wait_switch: Optional[float] = None) -> SqlserverReadonlyInstancefunc GetSqlserverReadonlyInstance(ctx *Context, name string, id IDInput, state *SqlserverReadonlyInstanceState, opts ...ResourceOption) (*SqlserverReadonlyInstance, error)public static SqlserverReadonlyInstance Get(string name, Input<string> id, SqlserverReadonlyInstanceState? state, CustomResourceOptions? opts = null)public static SqlserverReadonlyInstance get(String name, Output<String> id, SqlserverReadonlyInstanceState state, CustomResourceOptions options)resources:  _:    type: tencentcloud:SqlserverReadonlyInstance    get:      id: ${id}- 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.
- AutoVoucher double
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- AvailabilityZone string
- Availability zone.
- ChargeType string
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- CreateTime string
- Create time of the SQL Server instance.
- DnsPod stringDomain 
- Internet address domain name.
- EngineVersion string
- Version of the SQL Server database engine.
- ForceUpgrade bool
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- HaType string
- Instance type.
- MasterInstance stringId 
- Indicates the master instance ID of recovery instances.
- Memory double
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- Name string
- Name of the SQL Server instance.
- Period double
- Purchase instance period in month. The value does not exceed 48.
- ProjectId double
- Project ID.
- ReadonlyGroup stringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- ReadonlyGroup stringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- ReadonlyGroup doubleType 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- ReadonlyGroups doubleIs Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- ReadonlyGroups doubleMax Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- ReadonlyGroups doubleMin In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- RoFlag string
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- SecurityGroups List<string>
- Security group bound to the instance.
- SqlserverReadonly stringInstance Id 
- ID of the resource.
- Status double
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- Storage double
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- SubnetId string
- ID of subnet.
- Dictionary<string, string>
- The tags of the SQL Server.
- TgwWan doubleVport 
- External port number.
- TimeZone string
- System time zone, default: China Standard Time.
- Vip string
- IP for private access.
- VoucherIds List<string>
- An array of voucher IDs, currently only one can be used for a single order.
- VpcId string
- ID of VPC.
- Vport double
- Port for private access.
- WaitSwitch double
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- AutoVoucher float64
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- AvailabilityZone string
- Availability zone.
- ChargeType string
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- CreateTime string
- Create time of the SQL Server instance.
- DnsPod stringDomain 
- Internet address domain name.
- EngineVersion string
- Version of the SQL Server database engine.
- ForceUpgrade bool
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- HaType string
- Instance type.
- MasterInstance stringId 
- Indicates the master instance ID of recovery instances.
- Memory float64
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- Name string
- Name of the SQL Server instance.
- Period float64
- Purchase instance period in month. The value does not exceed 48.
- ProjectId float64
- Project ID.
- ReadonlyGroup stringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- ReadonlyGroup stringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- ReadonlyGroup float64Type 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- ReadonlyGroups float64Is Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- ReadonlyGroups float64Max Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- ReadonlyGroups float64Min In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- RoFlag string
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- SecurityGroups []string
- Security group bound to the instance.
- SqlserverReadonly stringInstance Id 
- ID of the resource.
- Status float64
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- Storage float64
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- SubnetId string
- ID of subnet.
- map[string]string
- The tags of the SQL Server.
- TgwWan float64Vport 
- External port number.
- TimeZone string
- System time zone, default: China Standard Time.
- Vip string
- IP for private access.
- VoucherIds []string
- An array of voucher IDs, currently only one can be used for a single order.
- VpcId string
- ID of VPC.
- Vport float64
- Port for private access.
- WaitSwitch float64
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- autoVoucher Double
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- availabilityZone String
- Availability zone.
- chargeType String
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- createTime String
- Create time of the SQL Server instance.
- dnsPod StringDomain 
- Internet address domain name.
- engineVersion String
- Version of the SQL Server database engine.
- forceUpgrade Boolean
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- haType String
- Instance type.
- masterInstance StringId 
- Indicates the master instance ID of recovery instances.
- memory Double
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- name String
- Name of the SQL Server instance.
- period Double
- Purchase instance period in month. The value does not exceed 48.
- projectId Double
- Project ID.
- readonlyGroup StringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- readonlyGroup StringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- readonlyGroup DoubleType 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- readonlyGroups DoubleIs Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- readonlyGroups DoubleMax Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- readonlyGroups DoubleMin In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- roFlag String
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- securityGroups List<String>
- Security group bound to the instance.
- sqlserverReadonly StringInstance Id 
- ID of the resource.
- status Double
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- storage Double
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- subnetId String
- ID of subnet.
- Map<String,String>
- The tags of the SQL Server.
- tgwWan DoubleVport 
- External port number.
- timeZone String
- System time zone, default: China Standard Time.
- vip String
- IP for private access.
- voucherIds List<String>
- An array of voucher IDs, currently only one can be used for a single order.
- vpcId String
- ID of VPC.
- vport Double
- Port for private access.
- waitSwitch Double
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- autoVoucher number
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- availabilityZone string
- Availability zone.
- chargeType string
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- createTime string
- Create time of the SQL Server instance.
- dnsPod stringDomain 
- Internet address domain name.
- engineVersion string
- Version of the SQL Server database engine.
- forceUpgrade boolean
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- haType string
- Instance type.
- masterInstance stringId 
- Indicates the master instance ID of recovery instances.
- memory number
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- name string
- Name of the SQL Server instance.
- period number
- Purchase instance period in month. The value does not exceed 48.
- projectId number
- Project ID.
- readonlyGroup stringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- readonlyGroup stringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- readonlyGroup numberType 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- readonlyGroups numberIs Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- readonlyGroups numberMax Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- readonlyGroups numberMin In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- roFlag string
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- securityGroups string[]
- Security group bound to the instance.
- sqlserverReadonly stringInstance Id 
- ID of the resource.
- status number
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- storage number
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- subnetId string
- ID of subnet.
- {[key: string]: string}
- The tags of the SQL Server.
- tgwWan numberVport 
- External port number.
- timeZone string
- System time zone, default: China Standard Time.
- vip string
- IP for private access.
- voucherIds string[]
- An array of voucher IDs, currently only one can be used for a single order.
- vpcId string
- ID of VPC.
- vport number
- Port for private access.
- waitSwitch number
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- auto_voucher float
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- availability_zone str
- Availability zone.
- charge_type str
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- create_time str
- Create time of the SQL Server instance.
- dns_pod_ strdomain 
- Internet address domain name.
- engine_version str
- Version of the SQL Server database engine.
- force_upgrade bool
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- ha_type str
- Instance type.
- master_instance_ strid 
- Indicates the master instance ID of recovery instances.
- memory float
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- name str
- Name of the SQL Server instance.
- period float
- Purchase instance period in month. The value does not exceed 48.
- project_id float
- Project ID.
- readonly_group_ strid 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- readonly_group_ strname 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- readonly_group_ floattype 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- readonly_groups_ floatis_ offline_ delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- readonly_groups_ floatmax_ delay_ time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- readonly_groups_ floatmin_ in_ group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- ro_flag str
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- security_groups Sequence[str]
- Security group bound to the instance.
- sqlserver_readonly_ strinstance_ id 
- ID of the resource.
- status float
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- storage float
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- subnet_id str
- ID of subnet.
- Mapping[str, str]
- The tags of the SQL Server.
- tgw_wan_ floatvport 
- External port number.
- time_zone str
- System time zone, default: China Standard Time.
- vip str
- IP for private access.
- voucher_ids Sequence[str]
- An array of voucher IDs, currently only one can be used for a single order.
- vpc_id str
- ID of VPC.
- vport float
- Port for private access.
- wait_switch float
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
- autoVoucher Number
- Whether to use the voucher automatically; 1 for yes, 0 for no, the default is 0.
- availabilityZone String
- Availability zone.
- chargeType String
- Pay type of the SQL Server instance. Available values PREPAID,POSTPAID_BY_HOUR.
- createTime String
- Create time of the SQL Server instance.
- dnsPod StringDomain 
- Internet address domain name.
- engineVersion String
- Version of the SQL Server database engine.
- forceUpgrade Boolean
- Indicate that the master instance upgrade or not. truefor upgrading the master SQL Server instance to cluster type by force. Default is false. Note: this is not supported withDUAL(ha_type),2017(engine_version) master SQL Server instance, for it will cause ha_type of the master SQL Server instance change.
- haType String
- Instance type.
- masterInstance StringId 
- Indicates the master instance ID of recovery instances.
- memory Number
- Memory size (in GB). Allowed value must be larger than memorythat data sourcetencentcloud_sqlserver_specinfosprovides.
- name String
- Name of the SQL Server instance.
- period Number
- Purchase instance period in month. The value does not exceed 48.
- projectId Number
- Project ID.
- readonlyGroup StringId 
- ID of the readonly group that this instance belongs to. When readonly_group_typeset value3, it must be set with valid value.
- readonlyGroup StringName 
- Required when readonly_group_type=2, the name of the newly created read-only group.
- readonlyGroup NumberType 
- Type of readonly group. Valid values: 1,3.1for one auto-assigned readonly instance per one readonly group,2for creating new readonly group,3for all exist readonly instances stay in the exist readonly group. For now, only1and3are supported.
- readonlyGroups NumberIs Offline Delay 
- Required when readonly_group_type=2, whether the newly created read-only group has delay elimination enabled, 1-enabled, 0-disabled. When the delay between the read-only copy and the primary instance exceeds the threshold, it is automatically removed.
- readonlyGroups NumberMax Delay Time 
- Required when readonly_group_type=2 andreadonly_groups_is_offline_delay=1, the threshold for delayed elimination of newly created read-only groups.
- readonlyGroups NumberMin In Group 
- When readonly_group_type=2 andreadonly_groups_is_offline_delay=1, it is required. After the newly created read-only group is delayed and removed, at least the number of read-only copies should be retained.
- roFlag String
- Readonly flag. RO(read-only instance),MASTER(primary instance with read-only instances). If it is left empty, it refers to an instance which is not read-only and has no RO group.
- securityGroups List<String>
- Security group bound to the instance.
- sqlserverReadonly StringInstance Id 
- ID of the resource.
- status Number
- Status of the SQL Server instance. 1 for applying, 2 for running, 3 for running with limit, 4 for isolated, 5 for recycling, 6 for recycled, 7 for running with task, 8 for off-line, 9 for expanding, 10 for migrating, 11 for readonly, 12 for rebooting.
- storage Number
- Disk size (in GB). Allowed value must be a multiple of 10. The storage must be set with the limit of storage_minandstorage_maxwhich data sourcetencentcloud_sqlserver_specinfosprovides.
- subnetId String
- ID of subnet.
- Map<String>
- The tags of the SQL Server.
- tgwWan NumberVport 
- External port number.
- timeZone String
- System time zone, default: China Standard Time.
- vip String
- IP for private access.
- voucherIds List<String>
- An array of voucher IDs, currently only one can be used for a single order.
- vpcId String
- ID of VPC.
- vport Number
- Port for private access.
- waitSwitch Number
- It has been deprecated from version 1.81.2. The way to execute the allocation. Supported values include: 0 - execute immediately, 1 - execute in maintenance window.
Import
SQL Server readonly instance can be imported using the id, e.g.
$ pulumi import tencentcloud:index/sqlserverReadonlyInstance:SqlserverReadonlyInstance example mssqlro-3cdq7kx5
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- tencentcloud tencentcloudstack/terraform-provider-tencentcloud
- License
- Notes
- This Pulumi package is based on the tencentcloudTerraform Provider.