CreateDBCluster.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
polardb:CreateDBCluster | create | *All Resources * |
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | Region ID. Note
You can view available regions through the DescribeRegions interface.
| cn-hangzhou |
ZoneId | string | No | Availability Zone ID. Note
You can view the available zones through the DescribeRegions interface.
| cn-hangzhou-j |
Architecture | string | No | CPU architecture. Available values include:
| X86 |
DBType | string | Yes | Database engine type, with available values as follows:
| MySQL |
DBVersion | string | Yes | Database engine version number.
| 5.6 |
DBNodeClass | string | Yes | Node specifications. For details, refer to the following documents:
Note
| polar.mysql.x4.medium |
ClusterNetworkType | string | No | Cluster network type, currently only VPC is supported, with a fixed value of VPC. | VPC |
DBClusterDescription | string | No | Cluster name, which must meet the following requirements:
| test |
PayType | string | Yes | Payment type, with available values as follows:
| Postpaid |
AutoRenew | boolean | No | Whether to enable auto-renewal, with available values as follows:
The default is false. Note
This parameter takes effect only when PayType is set to Prepaid.
| true |
Period | string | No | If the payment type is Prepaid, this parameter is required. It specifies whether the prepaid cluster is on a monthly or yearly basis.
| Month |
UsedTime | string | No | If the payment type is Prepaid, this parameter is required.
| 1 |
VPCId | string | No | VPC ID. | vpc-********** |
VSwitchId | string | No | Virtual switch ID. Note
If VPCId has been selected, VSwitchId is mandatory.
| vsw-********** |
CreationOption | string | No | Creation method, with the following values supported:
The default value is Normal. Note
When DBType is MySQL and DBVersion is 8.0, this parameter can also take the value CreateGdnStandby.
| Normal |
SourceResourceId | string | No | Source RDS instance ID or source PolarDB cluster ID. This parameter is mandatory only when CreationOption is set to MigrationFromRDS, CloneFromRDS, CloneFromPolarDB, or RecoverFromRecyclebin.
| rm-************* |
CloneDataPoint | string | No | The point in time to clone data, with the following options:
The default value is LATEST. Note
If CreationOption is CloneFromRDS, this parameter can only be set to LATEST.
| LATEST |
ClientToken | string | No | Used to ensure idempotency of the request. Generated by the client, ensuring uniqueness across different requests, case-sensitive, and not exceeding 64 ASCII characters. | 6000170000591aed949d0f5******************** |
ResourceGroupId | string | No | Resource group ID. | rg-************ |
SecurityIPList | string | No | PolarDB cluster whitelist IP address. Note
Supports configuring multiple whitelist IP addresses, with English commas separating multiple IP addresses.
| 10.***.***.*** |
TDEStatus | boolean | No | Enables TDE encryption. Valid values are as follows:
Note
| true |
GDNId | string | No | Global Database Network (GDN) ID. Note
This parameter is required when CreationOption is CreateGdnStandby.
| gdn-*********** |
CreationCategory | string | No | Product series, with valid values as follows:
Note
For more information about product series, see Product Series. | Normal |
DefaultTimeZone | string | No | Cluster timezone (UTC), with selectable values ranging from -12:00 to +13:00 at whole-hour intervals, e.g., 00:00. The default value is SYSTEM, which matches the Region's timezone. Note
This parameter applies only when DBType is MySQL.
| SYSTEM |
LowerCaseTableNames | string | No | Whether table names are case-sensitive, with valid values as follows:
The default value is 1. Note
This parameter applies only when DBType is MySQL.
| 1 |
BackupRetentionPolicyOnClusterDeletion | string | No | Backup retention policy upon cluster deletion, with valid values as follows:
By default, the value is set to NONE, indicating no backup sets are retained upon cluster deletion. Note
This parameter applies only when DBType is MySQL.
Serverless clusters do not support this parameter.
| NONE |
StorageSpace | long | No | Storage space for pay-by-space (subscription) billing. Unit: GB. Note
| 50 |
DBMinorVersion | string | No | Database engine minor version number. Valid values include:
Note
This parameter takes effect only when DBType is MySQL and DBVersion is 8.0.
| 8.0.1 |
ParameterGroupId | string | No | Parameter template ID. Note
You can view the list of parameter templates in the target region, including the parameter template ID, by calling the DescribeParameterGroups interface.
| pcpg-************** |
Tag | array<object> | No | List of tags. | |
object | No | |||
Key | string | No | Tag key. If you need to add multiple tags to the target cluster at once, click Add to add a tag key. Note
Up to 20 pairs of tags can be added each time, where Tag.N.Key corresponds to Tag.N.Value .
| type |
Value | string | No | Tag value. If you need to add multiple tags to the target cluster at once, click Add to add tag values. Note
Up to 20 pairs of tags can be added each time, where Tag.N.Value corresponds to Tag.N.Key .
| test |
ServerlessType | string | No | Serverless type. The current value is fixed to AgileServerless (sensitive mode). Note
This parameter is only supported by Serverless clusters.
| AgileServerless |
ScaleMin | string | No | Minimum scaling limit for a single node. The value range is: 1 PCU~31 PCU. Note
Only supported by Serverless clusters.
| 1 |
ScaleMax | string | No | Maximum scaling limit for a single node. The value range is: 1 PCU~32 PCU. Note
Only supported by Serverless clusters.
| 3 |
AllowShutDown | string | No | Whether to enable idle pause. Values:
Note
Only supported by Serverless clusters.
| true |
ScaleRoNumMin | string | No | Minimum scaling limit for the number of read-only nodes. The value range is: 0~15. Note
Only supported by Serverless clusters.
| 2 |
ScaleRoNumMax | string | No | Maximum scaling limit for the number of read-only nodes. The value range is: 0~15. Note
Only supported by Serverless clusters.
| 4 |
StorageType | string | No | Enterprise edition storage types include:
Standard edition storage types include:
| PSL4 |
DBNodeNum | integer | No | The number of nodes. This parameter is supported for Standard Edition clusters. Valid values:
Note
| 1 |
HotStandbyCluster | string | No | Whether to enable the hot standby cluster. Values are as follows:
Note
The default value for standard edition clusters is STANDBY.
| ON |
StrictConsistency | string | No | Whether the cluster has enabled strong data consistency across multiple zones. Values are as follows:
| ON |
StandbyAZ | string | No | The availability zone where the hot standby cluster is stored. Applicable to the standard edition 3AZ scenario. Note
This parameter takes effect only when multi-zone data strong consistency is enabled.
| cn-hangzhou-g |
ProxyType | string | No | Database proxy type, with values including:
Note
The proxy type must match the type of the cluster's node specifications, i.e.,
| Exclusive |
ProxyClass | string | No | Standard edition database proxy specifications. Values are as follows:
| polar.maxscale.g2.medium.c |
LoosePolarLogBin | string | No | Enable Binlog feature, valid values are as follows:
| ON |
LooseXEngine | string | No | Enable the X-Engine storage engine feature, with valid values as follows:
Note
This parameter is effective only when CreationOption is not CreateGdnStandby, DBType is MySQL, and DBVersion is 8.0. The memory specification of nodes that enable the X-Engine engine must be at least 8 GB.
| ON |
LooseXEngineUseMemoryPct | string | No | Set the ratio for enabling the X-Engine storage engine, with a range of integers from 10 to 90. Note
This parameter takes effect only when LooseXEngine is ON.
| 50 |
StoragePayType | string | No | The storage billing type, with valid values as follows:
| Prepaid |
StorageAutoScale | string | No | Whether to enable automatic storage expansion for standard edition clusters, with valid values as follows:
| Enable |
StorageUpperBound | long | No | Set the upper limit for automatic storage expansion of standard edition clusters, in GB. Note
The maximum value is 32000.
| 800 |
ProvisionedIops | long | No | The provisioned read and write IOPS for ESSD AutoPL cloud disks. Possible values: 0 to min{50,000, 1000*capacity-Baseline Performance}. Baseline Performance = min{1,800+50*capacity, 50000}. Note This parameter is supported only when StorageType is ESSDAUTOPL. | 1000 |
Response parameters
Examples
Sample success responses
JSON
format
{
"DBClusterId": "pc-bp1s826a1up******",
"OrderId": "211454967******",
"RequestId": "E56531A4-E552-40BA-9C58-137B80******",
"ResourceGroupId": "rg-***************"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | InvalidBackupRetentionPolicyOnClusterDeletion.Malformed | The specified BackupRetentionPolicyOnClusterDeletion is invalid. | The specified BackupRetentionPolicyOnClusterDeletion parameter is invalid. |
400 | InvalidLowerCaseTableNames.Malformed | The specified LowerCaseTableNames is invalid. | The specified LowerCaseTableNames parameter is invalid. |
400 | InvalidDefaultTimeZone.Malformed | The specified DefaultTimeZone is invalid. | The specified DefaultTimeZone parameter is invalid. |
400 | Location.FailedGetSubDomain | The specified regionId does not match the zoneId or the zoneId does not exist. | The specified region ID or zone ID is invalid or the specified zone ID does not exist. |
400 | InvalidLowerCaseTableNames.Malformed | The specified LowerCaseTableNames value is invalid. | The specified lowercase letter name is invalid. |
400 | MissParameter.GDNId | The GDNId parameter is required. | The GDNId parameter is required. |
400 | EntityNotExist.ResourceGroup | The resource group does not exist.. | The resource group does not exist. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2023-11-16 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2023-10-12 | The Error code has changed | View Change Details |
2023-08-03 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2023-08-01 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2023-06-20 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2023-05-25 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2023-04-19 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2023-03-14 | The Error code has changed. The request parameters of the API has changed | View Change Details |
2022-11-16 | The Error code has changed | View Change Details |
2022-11-02 | The Error code has changed. The request parameters of the API has changed | View Change Details |