DescribeDCDBShards

Last updated: 2020-04-02 17:51:44

    1. API Description

    Domain name for API request: dcdb.tencentcloudapi.com.

    This API is used to query the information of shards of a TencentDB instance.

    A maximum of 20 requests can be initiated per second for this API.

    Note: This API supports Finance regions. If the common parameter Region is a Finance region, a domain name with the Finance region needs to be specified, for example: dcdb.ap-shanghai-fsi.tencentcloudapi.com

    2. Input Parameters

    The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

    Parameter Name Required Type Description
    Action Yes String Common parameter. The value used for this API: DescribeDCDBShards.
    Version Yes String Common parameter. The value used for this API: 2018-04-11.
    Region Yes String Common parameter. For more information, please see the list of regions supported by the product.
    InstanceId Yes String Instance ID in the format of dcdbt-ow728lmc.
    ShardInstanceIds.N No Array of String Shard ID list.
    Offset No Integer Offset. Default value: 0
    Limit No Integer Number of returned results. Default value: 20. Maximum value: 100.
    OrderBy No String Sort by field. Only createtime is supported currently
    OrderByType No String Sort by type. Valid values: desc; asc

    3. Output Parameters

    Parameter Name Type Description
    TotalCount Integer Number of eligible shards
    Shards Array of DCDBShardInfo Shard information list
    RequestId String The unique request ID, which is returned for each request. RequestId is required for locating a problem.

    4. Example

    Example1 Query cloud database sharding information

    Input Example

    https://dcdb.tencentcloudapi.com/?Action=DescribeDCDBShards
    &InstanceId=dcdbt-ovulpcjf
    &<common request parameters>

    Output Example

    {
      "Response": {
        "RequestId": "09d5c691-c180-4c7f-8bcf-1ef6d1bab40c",
        "TotalCount": 2,
        "Shards": [
          {
            "ShardId": 10244,
            "InstanceId": "dcdbt-ovulpcjf",
            "ShardSerialId": "set_1536756357_1",
            "ShardInstanceId": "shard-5d4efnj7",
            "Status": 2,
            "StatusDesc": "running",
            "CreateTime": "2018-09-12 20:44:47",
            "VpcId": "vpc-5rkcp0wb",
            "SubnetId": "subnet-6ffate6q",
            "ProjectId": 0,
            "Region": "ap-guangzhou",
            "Zone": "ap-guangzhou-1",
            "Memory": 2,
            "Storage": 10,
            "PeriodEndTime": "2018-10-12 20:44:47",
            "NodeCount": 2,
            "StorageUsage": 0.1,
            "MemoryUsage": 37.2
          },
          {
            "ShardId": 10245,
            "InstanceId": "dcdbt-ovulpcjf",
            "ShardSerialId": "set_1536756415_3",
            "ShardInstanceId": "shard-8huhv1y9",
            "Status": 2,
            "StatusDesc": "running",
            "CreateTime": "2018-09-12 20:44:47",
            "VpcId": "vpc-5rkcp0wb",
            "SubnetId": "subnet-6ffate6q",
            "ProjectId": 0,
            "Region": "ap-guangzhou",
            "Zone": "ap-guangzhou-1",
            "Memory": 2,
            "Storage": 10,
            "PeriodEndTime": "2018-10-12 20:44:47",
            "NodeCount": 2,
            "StorageUsage": 0.1,
            "MemoryUsage": 15.1
          }
        ]
      }
    }

    5. Developer Resources

    API Explorer

    This tool allows online call, signature authentication, SDK code generation and quick search of APIs to greatly improve the efficiency of using TencentCloud APIs.

    SDK

    TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

    Command Line Interface

    6. Error Code

    The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

    Error Code Description
    InternalError.CamAuthFailed CAM authentication request failed.
    InternalError.DbOperationFailed Failed to query the database.
    InternalError.FenceError Failed to query the information of a dedicated cluster.
    InternalError.GetInstanceDetailFailed Failed to get the instance details.
    InternalError.GetInstanceInfoFailed Failed to get the instance information.
    InternalError.GetVpcFailed Failed to query the VPC information.
    InternalError.InnerSystemError Internal system error.
    InvalidParameter.GenericParameterError An error occurred while verifying parameter validity.
    InvalidParameterValue.IllegalExclusterID The dedicated cluster to which the database instance belongs was not found.
    InvalidParameterValue.SpecIdIllegal The specification information of the database instance was not found.
    UnauthorizedOperation.PermissionDenied You have no permission to manipulate this API or resource.

    Was this page helpful?

    Was this page helpful?

    • Not at all
    • Not very helpful
    • Somewhat helpful
    • Very helpful
    • Extremely helpful
    Send Feedback
    Help