Queries the detailed attributes of a PolarDB cluster.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

ParameterTypeRequiredExampleDescription
ActionStringYesDescribeDBClusterAttribute

The action that you want to perform. Set the value to DescribeDBClusterAttribute.

DBClusterIdStringYespc-*****************

The ID of the cluster.

Note You can call the DescribeDBClusters operation to query the details of the clusters that belong to your Alibaba Cloud account, such as cluster IDs.

Response parameters

ParameterTypeExampleDescription
DeletionLockInteger0

Indicates whether the cluster is locked and can be deleted. Valid values:

  • 0: The cluster is not locked and can be deleted.
  • 1: The cluster is locked and cannot be deleted.
CategoryStringNormal

The edition of PolarDB. Valid values:

  • Normal: Cluster Edition
  • Basic: Single Node Edition
  • Archive: X-Engine Edition
  • NormalMultimaster: Multi-master Cluster Edition
Note
  • Only PolarDB for MySQL supports Single Node Edition.
  • Only PolarDB for MySQL 8.0 supports X-Engine Edition and Multi-master Cluster Edition.
ResourceGroupIdStringrg-***************

The ID of the resource group.

DataLevel1BackupChainSizeLong74448896

The total physical storage of level-1 backups (snapshots). Unit: bytes.

DBClusterIdStringpc-*****************

The ID of the cluster.

DBTypeStringMySQL

The type of the engine.

DBClusterNetworkTypeStringVPC

The network type of the cluster.

IsLatestVersionBooleanfalse

Indicates whether the kernel is of the latest version. Valid values:

  • true
  • false
StorageMaxLong10995116277760

The maximum storage capacity of the current cluster specification. Unit: bytes.

DBVersionString8.0

The version of the engine.

DBNodesArray of DBNode

Details about the nodes.

CreationTimeString2020-03-23T21:35:43Z

The time when the node was created.

FailoverPriorityInteger1

The failover priority. Each node is assigned a failover priority. If a failover occurs, a node can be selected as a primary node. The priority determines the probability at which a node is selected as a primary node. A larger value indicates a higher priority. Valid values: 1 to 15.

MaxIOPSInteger32000

The maximum IOPS.

DBNodeClassStringpolar.mysql.x4.large

The specifications of the node.

DBNodeRoleStringReader

The role of the node. Valid values:

  • Writer: The node is the primary node.
  • Reader: The node is a read-only node.
ZoneIdStringcn-hangzhou-i

The zone ID of the cluster.

MaxConnectionsInteger8000

The maximum number of concurrent connections in the cluster.

DBNodeStatusStringRunning

The status of the node. Valid values:

  • Creating: PolarProxy is being created.
  • Running: PolarProxy is running.
  • Deleting: The cluster is being deleted.
  • Rebooting: The cluster is restarting.
  • DBNodeCreating: The node is being added.
  • DBNodeDeleting: The node is being deleted.
  • ClassChanging: The specifications of the node are being changed.
  • NetAddressCreating: The network connection is being created.
  • NetAddressDeleting: The network connection is being deleted.
  • NetAddressModifying: The network connection is being modified.
  • MinorVersionUpgrading: The minor version is being updated.
  • Maintaining: The instance is being maintained.
  • Switching: A failover is being performed.
DBNodeIdStringpi-****************

The ID of the node.

ImciSwitchStringON

Indicates whether the In-Memory Column Index (IMCI) feature is enabled. Valid values:

  • ON
  • OFF
HotReplicaModeStringON

Indicates whether the hot standby feature is enabled. Valid values:

  • ON
  • OFF
AddedCpuCoresString6

The number of CPU cores for compute node scale-out within seconds.

MasterIdStringpi-bp18z52akld3*****

The ID of the primary node in the Multi-master Cluster Edition cluster.

SccModeStringON

Indicates whether the SCC feature is enabled for the node. Valid values:

  • ON
  • OFF
ServerWeightString1

The routing weight of the node. Valid values: 1 to 100. Default value: 1.

ZoneIdsStringcn-hangzhou-i,cn-hangzhou-g

The zone ID of the cluster.

MaintainTimeString18:00Z-19:00Z

The maintenance window of the cluster. The format is HH:mmZ-HH:mmZ. The time is displayed in UTC. For example, the value 16:00Z-17:00Z indicates that the cluster can be maintained from 00:00 to 01:00 (UTC+08:00).

EngineStringPOLARDB

The database type.

TagsArray of Tag

The details of the tag.

KeyStringtest

A tag key.

ValueStringMySQL

The value of the tag that you want to create for the cluster.

RequestIdString074467EF-86B9-4C23-ACBF-E9B81A******

The ID of the request.

VPCIdStringvpc-*******************

The VPC ID of the cluster.

DBClusterStatusStringRunning

The state of the clusters that you want to query. For information about valid values, see Cluster status.

VSwitchIdStringvsw-*********************

The vSwitch ID of the cluster.

DBClusterDescriptionStringtest

The description of the cluster.

ExpiredStringfalse

Indicates whether the cluster has expired. Valid values:

Note This parameter is returned only for clusters that use the subscription billing method.
PayTypeStringPrepaid

The billing method of the cluster. Valid values:

  • Postpaid: pay-as-you-go.
  • Prepaid: subscription
StoragePayTypeStringPrepaid

The billing method of the storage. Valid values:

  • Postpaid: pay-as-you-go
  • Prepaid: subscription.
LockModeStringUnlock

The lock mode. Valid values:

  • Unlock: The cluster is not locked.
  • ManualLock: The cluster is manually locked.
  • LockByExpiration: The cluster is automatically locked because the cluster has expired.
StorageUsedLong3012558848

The storage space consumed by the cluster. Unit: bytes.

StorageSpaceLong50

The storage space that uses the subscription billing method. Unit: GB.

DBVersionStatusStringStable

The status of the minor version. Valid values:

  • Stable: The minor version is stable.
  • Old: The minor version is outdated. We recommend that you upgrade the cluster to the latest version.
  • HighRisk: The minor version has critical defects. We recommend that you immediately upgrade the cluster to the latest version.
Note For more information about how to upgrade the minor version, see Upgrade versions.
CreationTimeString2020-08-14T05:58:42Z

The time when the cluster was created.

SQLSizeLong0

The storage of SQL. Unit: bytes. If the value is -1, no data is stored.

InodeTotalLong6,291,456

Maximum inodes in file system.

InodeUsedLong4,194,304

The current inode usage.

BlktagTotalLong7,864,320

Maximum blktags in file system.

BlktagUsedLong5,242,880

The current blktag usage.

RegionIdStringcn-hangzhou

The region ID of the cluster.

ExpireTimeString2020-11-14T16:00:00Z

The time when the cluster expires.

Note Expiration time is returned only for clusters that use the subscription billing method. An empty string is returned for clusters that use the pay-as-you-go billing method.
SubCategoryStringExclusive

The specification type of the compute node. Valid values:

  • Exclusive: dedicated
  • General: general-purpose
Note This parameter is returned for only PolarDB for MySQL clusters of Cluster Edition.
IsProxyLatestVersionBooleanfalse

Indicates whether PolarProxy uses the latest version. Valid values:

  • true
  • false
StorageTypeStringHighPerformance

The storage type. Set the value to HighPerformance.

ServerlessTypeStringAgileServerless

The type of the serverless cluster. Set the value to AgileServerless.

ProxyCpuCoresString4

The number of CPU cores for PolarProxy.

ProxyStandardCpuCoresString2

The number of CPU cores for PolarProxy Standard Enterprise Edition.

ProxyTypeStringExclusive

The type of PolarProxy. Valid values:

  • Exclusive: Dedicated Enterprise Edition
  • General: Standard Enterprise Edition
ProxyStatusStringRunning

The status of PolarProxy. Valid values:

  • Creating: PolarProxy is being created.
  • Running: PolarProxy is running.
  • Deleting: PolarProxy is being released.
  • Rebooting: PolarProxy is restarting.
  • DBNodeCreating: The node is being added.
  • DBNodeDeleting: The node is being deleted.
  • ClassChanging: The specifications of the node are being changed.
  • NetAddressCreating: The network connection is being created.
  • NetAddressDeleting: The network connection is being deleted.
  • NetAddressModifying: The network connection is being modified.
  • Deleted: PolarProxy is released.

Examples

Sample requests

http(s)://polardb.aliyuncs.com/?Action=DescribeDBClusterAttribute
&DBClusterId=pc-*****************
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeDBClusterAttributeResponse>
    <DeletionLock>0</DeletionLock>
    <Category>Normal</Category>
    <ResourceGroupId>rg-***************</ResourceGroupId>
    <DataLevel1BackupChainSize>74448896</DataLevel1BackupChainSize>
    <DBClusterId>pc-*****************</DBClusterId>
    <DBType>MySQL</DBType>
    <DBClusterNetworkType>VPC</DBClusterNetworkType>
    <IsLatestVersion>false</IsLatestVersion>
    <StorageMax>10995116277760</StorageMax>
    <DBVersion>8.0</DBVersion>
    <DBNodes>
        <CreationTime>2020-03-23T21:35:43Z</CreationTime>
        <FailoverPriority>1</FailoverPriority>
        <MaxIOPS>32000</MaxIOPS>
        <DBNodeClass>polar.mysql.x4.large</DBNodeClass>
        <DBNodeRole>Reader</DBNodeRole>
        <ZoneId>cn-hangzhou-i</ZoneId>
        <MaxConnections>8000</MaxConnections>
        <DBNodeStatus>Running</DBNodeStatus>
        <DBNodeId>pi-****************</DBNodeId>
        <ImciSwitch>ON</ImciSwitch>
        <HotReplicaMode>ON</HotReplicaMode>
        <AddedCpuCores>6</AddedCpuCores>
        <MasterId>pi-bp18z52akld3*****</MasterId>
        <SccMode>ON</SccMode>
        <ServerWeight>1</ServerWeight>
    </DBNodes>
    <ZoneIds>cn-hangzhou-i,cn-hangzhou-g</ZoneIds>
    <MaintainTime>18:00Z-19:00Z</MaintainTime>
    <Engine>POLARDB</Engine>
    <Tags>
        <Key>test</Key>
        <Value>MySQL</Value>
    </Tags>
    <RequestId>074467EF-86B9-4C23-ACBF-E9B81A******</RequestId>
    <VPCId>vpc-*******************</VPCId>
    <DBClusterStatus>Running</DBClusterStatus>
    <VSwitchId>vsw-*********************</VSwitchId>
    <DBClusterDescription>test</DBClusterDescription>
    <Expired>false</Expired>
    <PayType>Prepaid</PayType>
    <StoragePayType>Prepaid</StoragePayType>
    <LockMode>Unlock</LockMode>
    <StorageUsed>3012558848</StorageUsed>
    <StorageSpace>50</StorageSpace>
    <DBVersionStatus>Stable</DBVersionStatus>
    <CreationTime>2020-08-14T05:58:42Z</CreationTime>
    <SQLSize>0</SQLSize>
    <RegionId>cn-hangzhou</RegionId>
    <ExpireTime>2020-11-14T16:00:00Z</ExpireTime>
    <SubCategory>Exclusive</SubCategory>
    <IsProxyLatestVersion>false</IsProxyLatestVersion>
    <StorageType>HighPerformance</StorageType>
    <ServerlessType>AgileServerless</ServerlessType>
    <ProxyCpuCores>4</ProxyCpuCores>
    <ProxyStandardCpuCores>2</ProxyStandardCpuCores>
    <ProxyType>Exclusive</ProxyType>
    <ProxyStatus>Running</ProxyStatus>
</DescribeDBClusterAttributeResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "DeletionLock" : 0,
  "Category" : "Normal",
  "ResourceGroupId" : "rg-***************",
  "DataLevel1BackupChainSize" : 74448896,
  "DBClusterId" : "pc-*****************",
  "DBType" : "MySQL",
  "DBClusterNetworkType" : "VPC",
  "IsLatestVersion" : false,
  "StorageMax" : 10995116277760,
  "DBVersion" : "8.0",
  "DBNodes" : [ {
    "CreationTime" : "2020-03-23T21:35:43Z",
    "FailoverPriority" : 1,
    "MaxIOPS" : 32000,
    "DBNodeClass" : "polar.mysql.x4.large",
    "DBNodeRole" : "Reader",
    "ZoneId" : "cn-hangzhou-i",
    "MaxConnections" : 8000,
    "DBNodeStatus" : "Running",
    "DBNodeId" : "pi-****************",
    "ImciSwitch" : "ON",
    "HotReplicaMode" : "ON",
    "AddedCpuCores" : "6",
    "MasterId" : "pi-bp18z52akld3*****",
    "SccMode" : "ON",
    "ServerWeight" : "1"
  } ],
  "ZoneIds" : "cn-hangzhou-i,cn-hangzhou-g",
  "MaintainTime" : "18:00Z-19:00Z",
  "Engine" : "POLARDB",
  "Tags" : [ {
    "Key" : "test",
    "Value" : "MySQL"
  } ],
  "RequestId" : "074467EF-86B9-4C23-ACBF-E9B81A******",
  "VPCId" : "vpc-*******************",
  "DBClusterStatus" : "Running",
  "VSwitchId" : "vsw-*********************",
  "DBClusterDescription" : "test",
  "Expired" : "false",
  "PayType" : "Prepaid",
  "StoragePayType" : "Prepaid",
  "LockMode" : "Unlock",
  "StorageUsed" : 3012558848,
  "StorageSpace" : 50,
  "DBVersionStatus" : "Stable",
  "CreationTime" : "2020-08-14T05:58:42Z",
  "SQLSize" : 0,
  "RegionId" : "cn-hangzhou",
  "ExpireTime" : "2020-11-14T16:00:00Z",
  "SubCategory" : "Exclusive",
  "IsProxyLatestVersion" : false,
  "StorageType" : "HighPerformance",
  "ServerlessType" : "AgileServerless",
  "ProxyCpuCores" : "4",
  "ProxyStandardCpuCores" : "2",
  "ProxyType" : "Exclusive",
  "ProxyStatus" : "Running"
}

Error codes

HTTP status codeError codeError messageDescription
400InvalidDBClusterId.MalformedThe specified parameter DBClusterId is not valid.The error message returned because the specified DBClusterId is invalid.
404InvalidDBCluster.NotFoundThe DBClusterId provided does not exist in our records.The error message returned because the specified cluster ID does not exist in the current record.

For a list of error codes, see Service error codes.