All Products
Search
Document Center

Resource Orchestration Service:ALIYUN::ClickHouse::DBCluster

Last Updated:Nov 07, 2023

ALIYUN::ClickHouse::DBCluster is used to create an ApsaraDB for ClickHouse cluster.

Syntax

{
  "Type": "ALIYUN::ClickHouse::DBCluster",
  "Properties": {
    "DbNodeStorageType": String,
    "DBNodeStorage": Integer,
    "EncryptionType": String,
    "Category": String,
    "ZoneId": String,
    "VSwitchId": String,
    "DBClusterDescription": String,
    "Period": String,
    "EncryptionKey": String,
    "DBClusterNetworkType": String,
    "DBClusterType": String,
    "VpcId": String,
    "DBClusterVersion": String,
    "DBNodeCount": Integer,
    "UsedTime": Integer,
    "PaymentType": String
  }
}

Properties

Property

Type

Required

Editable

Description

Constraint

DbNodeStorageType

String

Yes

No

The storage type of the node.

Valid values:

  • cloud_essd: Enhanced SSD (ESSD)

  • cloud_efficiency: ultra disk

DBNodeStorage

Integer

Yes

Yes

The storage capacity of the node.

Valid values: 100 to 10000.

Unit: GB.

The value must be in increments of 100 GB.

EncryptionType

String

No

No

Specifies whether to enable disk encryption.

Set the value to CloudDisk. This value specifies that disk encryption is used for the cluster.

Category

String

Yes

No

The edition of the cluster.

Valid values:

  • Basic: Basic Edition

  • HighAvailability: Cluster Edition

ZoneId

String

No

No

The zone ID of the cluster.

You can call the DescribeRegions operation to query the most recent zone list.

VSwitchId

String

No

No

The vSwitch ID of the cluster.

None.

DBClusterDescription

String

No

Yes

The description of the cluster.

None.

Period

String

No

No

The billing cycle of the subscription cluster.

Valid values:

  • Year

  • Month

Note

This property is required if you set PaymentType to Prepaid.

EncryptionKey

String

No

No

The ID of the key that is provided by Key Management Service (KMS).

None.

DBClusterNetworkType

String

Yes

No

The network type of the cluster.

Set the value to VPC. This value specifies that the cluster is created in a virtual private cloud (VPC).

DBClusterType

String

Yes

Yes

The specification of the cluster.

  • If the cluster is of the Double-replica Edition, valid values are:

    • LC20: large-storage type, 20 cores, and 88 GB of memory

    • LC40: large-storage type, 40 cores, and 176 GB of memory

    • LC80: large-storage type, 80 cores, and 352 GB of memory

    • C8: standard type, 8 cores, and 32 GB of memory

    • C16: standard type, 16 cores, and 64 GB of memory

    • C32: standard type, 32 cores, and 128 GB of memory

    • C16: standard type, 64 cores, and 256 GB of memory

    • C80: standard type, 80 cores, and 384 GB of memory

    • C104: standard type, 104 cores, and 384 GB of memory

  • If the cluster is of the Single-replica Edition, valid values are:

    • LS20: large-storage type, 20 cores, and 88 GB of memory

    • LS40: large-storage type, 40 cores, and 176 GB of memory

    • LS80: large-storage type, 80 cores, and 352 GB of memory

    • S8: standard type, 8 cores, and 32 GB of memory

    • S16: standard type, 16 cores, and 64 GB of memory

    • S32: standard type, 32 cores, and 128 GB of memory

    • S64: standard type, 64 cores, and 256 GB of memory

    • S80: standard type, 80 cores, and 384 GB of memory

    • S104: standard type, 104 cores, and 384 GB of memory

VpcId

String

No

No

The VPC ID of the cluster.

None.

DBClusterVersion

String

Yes

No

The version of the cluster.

Valid values:

  • 21.8.10.19

  • 22.8.5.29

DBNodeCount

Integer

Yes

Yes

The number of nodes.

Valid values:

  • For S series clusters: 1 to 48.

  • For C series clusters: 1 to 24.

UsedTime

Integer

No

No

The usage duration of the cluster.

Valid values:

  • If you set Period to Month: 1, 2, 3, 4, 5, 6, 7, 8, and 9.

  • If you set Period to Year: 1, 2, and 3.

PaymentType

String

Yes

No

The billing method of the cluster.

Valid values:

  • Postpaid: pay-as-you-go

  • Prepaid: subscription

Return values

Fn::GetAtt

  • DBClusterId: the cluster ID.

  • PublicPort: the public port.

  • Bid: the business process ID.

  • LockReason: the reason why the cluster is locked.

  • LockMode: the lock mode.

  • DBClusterVersion: the cluster version.

  • CommodityCode: the commodity code.

  • VpcId: the VPC ID.

  • Engine: the cluster engine.

  • Category: the cluster edition.

  • DBClusterType: the cluster specification.

  • DBClusterNetworkType: the network type.

  • EncryptionType: indicates whether disk encryption is enabled.

  • VpcCloudInstanceId: the ID of the cluster of the VPC network type.

  • Port: the port number that is used to connect to the cluster.

  • PaymentType: the billing method.

  • DBNodeStorage: the storage capacity of the node.

  • PublicConnectionString: the public endpoint.

  • EngineVersion: the engine version.

  • IsExpired: indicates whether the cluster is expired.

  • VSwitchId: the vSwitch ID.

  • Period: the billing cycle of the subscription cluster.

  • StorageType: the storage type.

  • DBNodeCount: the number of node groups.

  • AliUid: the ID of the Alibaba Cloud account.

  • DBClusterDescription: the description of the cluster.

  • ConnectionString: the endpoint of the cluster.

  • ZoneId: the zone ID.

  • EncryptionKey: the ID of the key that is provided by KMS.

  • DbNodeStorageType: the storage type of the node.

  • DBNodeClass: the node type.

Examples

YAML format

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  VpcId:
    Type: String
    AssociationProperty: ALIYUN::ECS::VPC::VPCId
  ZoneId:
    Type: String
    AssociationProperty: ZoneId
  VSwitchId:
    Type: String
    AssociationProperty: ALIYUN::ECS::VSwitch::VSwitchId
    AssociationPropertyMetadata:
      ZoneId: ${ZoneId}
      VpcId: ${VpcId}
  PaymentType:
    Type: String
    Description: PayType
    Default: Month
Resources:
  ClickHouseDBCluster:
    Type: ALIYUN::ClickHouse::DBCluster
    Properties:
      DbNodeStorageType: cloud_essd
      DBNodeStorage: 100 
      Category: Basic
      ZoneId:
        Ref: ZoneId
      VSwitchId:
        Ref: VSwitchId
      Period: Month
      DBClusterNetworkType: VPC
      DBClusterType: S8
      VpcId:
        Ref: VpcId
      DBClusterVersion: 21.8.10.19
      DBNodeCount: 3
      UsedTime: 1
      PaymentType: Prepaid

JSON format

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "VpcId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::VPC::VPCId"
    },
    "ZoneId": {
      "Type": "String",
      "AssociationProperty": "ZoneId"
    },
    "VSwitchId": {
      "Type": "String",
      "AssociationProperty": "ALIYUN::ECS::VSwitch::VSwitchId",
      "AssociationPropertyMetadata": {
        "ZoneId": "${ZoneId}",
        "VpcId": "${VpcId}"
      }
    },
    "PaymentType": {
      "Type": "String",
      "Description": "PayType",
      "Default": "Month"
    }
  },
  "Resources": {
    "ClickHouseDBCluster": {
      "Type": "ALIYUN::ClickHouse::DBCluster",
      "Properties": {
        "DbNodeStorageType": "cloud_essd",
        "DBNodeStorage": 100,
        "Category": "Basic",
        "ZoneId": {
          "Ref": "ZoneId"
        },
        "VSwitchId": {
          "Ref": "VSwitchId"
        },
        "Period": "Month",
        "DBClusterNetworkType": "VPC",
        "DBClusterType": "S8",
        "VpcId": {
          "Ref": "VpcId"
        },
        "DBClusterVersion": "21.8.10.19",
        "DBNodeCount": 3,
        "UsedTime": 1,
        "PaymentType": "Prepaid"
      }
    }
  }
}