All Products
Search
Document Center

AnalyticDB:DescribeDBClusters

Last Updated:Aug 30, 2024

Queries a list of AnalyticDB for MySQL clusters within a region.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

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.
OperationAccess levelResource typeCondition keyAssociated operation
adb:DescribeDBClustersget
  • DBCluster
    acs:adb:{#regionId}:{#accountId}:dbcluster/*
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
RegionIdstringYes

The region ID of the clusters.

Note You can call the DescribeRegions operation to query the most recent region list.
cn-hangzhou
DBClusterIdsstringNo

The cluster IDs.

Note You can specify the ID of one cluster or IDs of more clusters within the preceding region.
am-bp1r053byu48p****
DBClusterDescriptionstringNo

The description of the cluster.

  • The description cannot start with http:// or https://.
  • The description must be 2 to 256 characters in length
test
DBClusterStatusstringNo

The state of the cluster. Valid values:

  • Preparing: The cluster is being prepared.
  • Creating: The cluster is being created.
  • Restoring: The cluster is being restored from a backup.
  • Running: The cluster is running.
  • Deleting: The cluster is being deleted.
  • ClassChanging: The cluster specifications are being changed.
  • NetAddressCreating: A network connection is being created.
  • NetAddressDeleting: A network connection is being deleted.
Running
PageSizeintegerNo

The number of entries per page. Valid values:

  • 30 (default)
  • 50
  • 100
30
PageNumberintegerNo

The page number. Pages start from page 1. Default value: 1.

1
ResourceGroupIdstringNo

The ID of the resource group.

rg-4690g37929XXXX
Tagarray<object>No

The tags that are added to the cluster.

objectNo

The tag that is added to the cluster.

KeystringNo

The key of tag N that is added to the cluster. You can use tags to filter clusters. A tag is a key-value pair. You can specify up to 20 tags in one request. The letter N specifies the sequence number of each key-value pair and must be unique. The values of N must be consecutive integers that start from 1. Each value of Tag.N.Key is paired with a value of Tag.N.Value.

Note The tag key can be up to 64 characters in length and cannot start with aliyun, acs:, http://, or https://.
tag1
ValuestringNo

The value of tag N that is added to the cluster. You can use tags to filter clusters. A tag is a key-value pair. You can specify up to 20 tags in one request. The letter N specifies the sequence number of each key-value pair and must be unique. The values of N must be consecutive integers that start from 1. Each value of Tag.N.Key is paired with a value of Tag.N.Value.

Note The tag key can be up to 64 characters in length and cannot start with aliyun, acs:, http://, or https://.
test1
DBVersionstringNo

The version of the cluster. Set the value to 3.0.

3.0

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

TotalCountinteger

The total number of entries returned.

1
PageSizeinteger

The number of entries per page.

30
RequestIdstring

The request ID.

D65A809F-34CE-4550-9BC1-0ED21ETG380
PageNumberinteger

The page number.

1
Itemsarray<object>

The queried clusters.

object

The queried cluster.

DtsJobIdstring

The ID of the Data Transmission Service (DTS) synchronization job. This parameter is returned only for MySQL analytic instances.

dtsb1578j90XXXX
DBNodeCountlong

The number of node groups.

1
Expiredstring

Indicates whether the cluster has expired. Valid values:

  • true
  • false
false
CreateTimestring

The time when the cluster was created. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. Example: 2021-04-01T09:50:18Z.

2021-04-01T09:50:18Z
PayTypestring

The billing method of the cluster. Valid values:

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

The disk type of the cluster. Valid values:

  • local_ssd: local SSD.
  • cloud: basic disk.
  • cloud_ssd: standard SSD.
  • cloud_efficiency: ultra disk.
  • cloud_essd0: PL0 Enterprise SSD (ESSD).
  • cloud_essd: PL1 ESSD.
  • cloud_essd2: PL2 ESSD.
  • cloud_essd3: PL3 ESSD.
Note For more information about ESSDs, see ESSDs .
cloud_essd
Tagsarray<object>

The tags that are added to the cluster.

object

The tag that is added to the cluster.

Keystring

The tag key.

Note You can call the TagResources operation to add a tag to the cluster.
tag1
Valuestring

The tag value.

test1
Modestring

The mode of the cluster. Valid values:

  • flexible: elastic mode.
  • reserver: reserved mode.
Note
  • For more information about cluster modes, see Editions .
flexible
Portstring

The port number that is used to connect to the cluster. Default value: 3306.

3306
LockModestring

The lock mode of the cluster. Valid values:

  • Unlock: The cluster is not locked.
  • ManualLock: The cluster is manually locked.
  • LockByExpiration: The cluster is automatically locked due to cluster expiration.
  • LockByRestoration: The cluster is automatically locked due to cluster restoration.
  • LockByDiskQuota: The cluster is automatically locked when 90% of the cluster storage is used.
Unlock
StorageResourcestring

The specifications of storage resources that are used in the cluster in elastic mode. Storage resources are used to read and write data. The increase in the storage resources can improve the read and write performance of the cluster.

8Core32GB
ExecutorCountstring

The number of compute nodes that are used by the cluster in elastic mode.

1
DBClusterIdstring

The cluster ID.

am-bp163885f8q21****
ConnectionStringstring

The public endpoint that is used to connect to the cluster.

am-bp163885f8q21****.ads.aliyuncs.com
RdsInstanceIdstring

The ID of the ApsaraDB RDS instance from which data is synchronized to the cluster. This parameter is returned only for MySQL analytic instances.

rm-bp11q28kvl688****
DBClusterTypestring

The type of the cluster. Valid values:

  • Common: common cluster.
  • RDS_ANALYSIS: MySQL analytic instance.
Common
CommodityCodestring

The commodity code. ads is returned.

ads
ExpireTimestring

The expiration time of the cluster. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. Example: 2999-09-08T16:00:00Z.

Note
  • If the billing method of the cluster is subscription, the actual expiration time is returned.

  • If the billing method of the cluster is pay-as-you-go, 2999-09-08T16:00:00Z is returned.

2999-09-08T16:00:00Z
DBNodeStoragelong

The storage capacity of the cluster. Unit: GB.

300
DBNodeClassstring

The specifications of the cluster.

E8
LockReasonstring

The reason why the cluster is locked.

Note This parameter is returned only when the cluster was locked. instance_expire is returned.
instance_expired
VPCIdstring

The virtual private cloud (VPC) ID of the cluster.

vpc-bp13h7uzhulpuxvnpXXXX
RegionIdstring

The region ID of the cluster.

cn-hangzhou
ComputeResourcestring

The specifications of computing resources that are used in the cluster in elastic mode. Computing resources are used to compute data. The increase in the computing resources can accelerate queries. You can scale computing resources based on your business requirements.

8Core32GB
ElasticIOResourceinteger

The number of elastic I/O units (EIUs). For more information, see Elasticity of the storage layer.

Note This parameter is returned only for clusters in elastic mode.
0
VSwitchIdstring

The vSwitch ID of the cluster.

vsw-bp1syh8vvw8yech7nXXXX
DBVersionstring

The version of the database engine. 3.0 is returned.

3.0
VPCCloudInstanceIdstring

The ID of the cluster that resides in the VPC.

am-bp163885f8q21****-controller
DBClusterStatusstring

The status of the cluster. For more information, see Cluster states.

Running
ResourceGroupIdstring

The resource group ID.

rg-acfmyiu4ekp****
DBClusterNetworkTypestring

The network type of the cluster. VPC is returned.

vpc
DBClusterDescriptionstring

The description of the cluster.

adb_test
ZoneIdstring

The zone ID of the cluster.

cn-hangzhou-h
Categorystring

The edition of the cluster. Valid values:

  • BASIC: reserved mode for Basic Edition.
  • CLUSTER: reserved mode for Cluster Edition.
  • MIXED_STORAGE: elastic mode for Cluster Edition.
Note For more information about cluster editions, see Editions .
MIXED_STORAGE
Enginestring

The engine of the cluster. AnalyticDB is returned.

AnalyticDB
InnerIpstring

The public IP address of the cluster.

10.1.xx.xx
InnerPortstring

The port number that is used to connect to the cluster.

3306
TaskInfoobject

The job progress.

Namestring

The name of the job.

analyticDBFlexibleScaleOut
Statusstring

The status of the job. Valid values:

  • NOT_RUN
  • RUNNING
  • SUCCEED
RUNNING
Progressstring

The progress of the job. Unit: %.

10
StepListarray<object>

The job steps.

object
StepNamestring

The name of the job step.

ApplyResource
StepDescstring

The description of the job step.

Apply resource
StepStatusstring

The status of the job step. Valid values:

  • NOT_RUN
  • RUNNING
  • SUCCEED
SUCCEED
StepProgressstring

The progress of the job step. Unit: %.

50
StartTimestring

The start time of the job step. The time follows the ISO 8601 standard in the YYYY-MM-DDThh:mm:ssZ format. The time is displayed in UTC.

2024-03-10T09:28:34Z
EndTimestring

The end time of the job step. The time follows the ISO 8601 standard in the YYYY-MM-DDThh:mm:ssZ format. The time is displayed in UTC.

2024-03-10T10:28:34Z
ProductVersionstring

The edition of the cluster. Valid values:

  • BasicVersion: Basic Edition.
  • EnterpriseVersion: Enterprise Edition.
EnterpriseVersion

Examples

Sample success responses

JSONformat

{
  "TotalCount": 1,
  "PageSize": 30,
  "RequestId": "D65A809F-34CE-4550-9BC1-0ED21ETG380",
  "PageNumber": 1,
  "Items": {
    "DBCluster": [
      {
        "DtsJobId": "dtsb1578j90XXXX",
        "DBNodeCount": 1,
        "Expired": "false",
        "CreateTime": "2021-04-01T09:50:18Z",
        "PayType": "Postpaid",
        "DiskType": "cloud_essd",
        "Tags": {
          "Tag": [
            {
              "Key": "tag1",
              "Value": "test1"
            }
          ]
        },
        "Mode": "flexible",
        "Port": "3306",
        "LockMode": "Unlock",
        "StorageResource": "8Core32GB",
        "ExecutorCount": "1",
        "DBClusterId": "am-bp163885f8q21****",
        "ConnectionString": "am-bp163885f8q21****.ads.aliyuncs.com",
        "RdsInstanceId": "rm-bp11q28kvl688****",
        "DBClusterType": "Common",
        "CommodityCode": "ads",
        "ExpireTime": "2999-09-08T16:00:00Z",
        "DBNodeStorage": 300,
        "DBNodeClass": "E8",
        "LockReason": "instance_expired",
        "VPCId": "vpc-bp13h7uzhulpuxvnpXXXX",
        "RegionId": "cn-hangzhou",
        "ComputeResource": "8Core32GB",
        "ElasticIOResource": 0,
        "VSwitchId": "vsw-bp1syh8vvw8yech7nXXXX",
        "DBVersion": "3.0",
        "VPCCloudInstanceId": "am-bp163885f8q21****-controller",
        "DBClusterStatus": "Running",
        "ResourceGroupId": "rg-acfmyiu4ekp****",
        "DBClusterNetworkType": "vpc",
        "DBClusterDescription": "adb_test",
        "ZoneId": "cn-hangzhou-h",
        "Category": "MIXED_STORAGE",
        "Engine": "AnalyticDB",
        "InnerIp": "10.1.xx.xx",
        "InnerPort": "3306",
        "TaskInfo": {
          "Name": "analyticDBFlexibleScaleOut",
          "Status": "RUNNING",
          "Progress": "10",
          "StepList": {
            "StepList": [
              {
                "StepName": "ApplyResource",
                "StepDesc": "Apply resource",
                "StepStatus": "SUCCEED",
                "StepProgress": "50",
                "StartTime": "2024-03-10T09:28:34Z",
                "EndTime": "2024-03-10T10:28:34Z"
              }
            ]
          }
        },
        "ProductVersion": "EnterpriseVersion"
      }
    ]
  }
}

Error codes

HTTP status codeError codeError messageDescription
500InternalErrorAn error occurred while processing your request.An internal error occurred. Please try again later.
503ServiceUnavailableAn error occurred while processing your request.The system is unavailable. Please try again later.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2024-05-28The Error code has changed. The response structure of the API has changedView Change Details
2024-04-01The Error code has changed. The response structure of the API has changedView Change Details