Queries the resource usage of a cluster.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DescribeClusterUsedUtilization | The operation that you want to perform. Set the value to DescribeClusterUsedUtilization. |
DedicatedClusterId | String | Yes | nodeid | The ID of the cluster. If MetricType is set to CLUSTER, enter the ID of the dedicated cluster. Otherwise, set this parameter to a node ID. |
Env | String | No | ALIYUN | The environment of the cluster. Default value: ALIYUN. |
MetricType | String | No | NODE | Specifies whether to query the metrics of the cluster or a node. Valid values:
|
RegionId | String | No | cn-hangzhou | The ID of the region in which the Data Transmission Service (DTS) instance resides. |
DtsJobId | String | No | k2gm967v16f**** | The ID of the data migration or synchronization task. |
ClientToken | String | No | 0c593ea1-3bea-11e9-b96b-88e9fe63**** | The client token that is used to ensure the idempotence of the request. You can use the client to generate the token, but you must make sure that the token is unique among different requests. The token can contain only ASCII characters and cannot exceed 64 characters in length. |
AccountId | String | No | 12323344**** | The ID of the Alibaba Cloud account. You do not need to specify this parameter because this parameter will be removed in the future. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
DedicatedClusterId | String | dtscluster_h3fl1cs217sx952 | The ID of the cluster. |
CpuTotal | Float | 50 | The CPU utilization of the cluster. Unit: %. |
MemoryUsed | Float | 0 | The used memory size of the cluster. A value of 0 is temporarily returned. |
MemoryTotal | Float | 0 | The total memory size of the cluster. A value of 0 is temporarily returned. |
DiskTotal | Float | 1024 | The total disk size of the cluster. Unit: GB. |
DiskUsed | Float | 96 | The used disk size of the cluster. Unit: GB. |
DuTotal | Integer | 30 | The total number of DTS units (DUs). |
DuUsed | Integer | 2 | The number of used DUs. |
TaskRunning | Integer | 3 | The number of tasks that are in progress. |
Success | Boolean | true | Indicates whether the request was successful. |
Code | String | 200 | The error code returned by the backend service. The number is incremented. |
ErrCode | String | InternalError | The error code returned if the request failed. |
ErrMessage | String | The Value of Input Parameter %s is not valid. | The error message returned if the request failed. |
DynamicMessage | String | Type | The dynamic part in the error message. This parameter is used to replace the %s variable in the value of ErrMessage. |
HttpStatusCode | Integer | 200 | The HTTP status code. |
RequestId | String | 621BB4F8-3016-4FAA-8D5A-5D3163CC**** | The ID of the request. |
MemoryUsedPercentage | Float | 1.0 | The memory usage. Unit: %. |
Examples
Sample requests
http(s)://dts.aliyuncs.com/?Action=DescribeClusterUsedUtilization
&DedicatedClusterId=nodeid
&Env=ALIYUN
&MetricType=NODE
&RegionId=cn-hangzhou
&DtsJobId=k2gm967v16f****
&ClientToken=0c593ea1-3bea-11e9-b96b-88e9fe63****
&AccountId=12323344****
&Common request parameters
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<DescribeClusterUsedUtilizationResponse>
<code>200</code>
<data>
<DedicatedClusterId>dtscluster_****</DedicatedClusterId>
<RequestId>E2E2AD3E-B7A4-106C-9063-****</RequestId>
<DuUsed>14</DuUsed>
<Success>true</Success>
<DuTotal>30</DuTotal>
<DiskTotal>982.3013</DiskTotal>
<HttpStatusCode>200</HttpStatusCode>
<MemoryUsedPercentage>5.5200005</MemoryUsedPercentage>
<MemoryUsed>0</MemoryUsed>
<TaskRunning>3</TaskRunning>
<DiskUsed>92.0647</DiskUsed>
<MemoryTotal>0</MemoryTotal>
<CpuTotal>1.7</CpuTotal>
</data>
<httpStatusCode>200</httpStatusCode>
<requestId>E2E2AD3E-B7A4-106C-9063-****</requestId>
<successResponse>true</successResponse>
</DescribeClusterUsedUtilizationResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"code" : "200",
"data" : {
"DedicatedClusterId" : "dtscluster_****",
"RequestId" : "E2E2AD3E-B7A4-106C-9063-****",
"DuUsed" : 14,
"Success" : true,
"DuTotal" : 30,
"DiskTotal" : 982.3013,
"HttpStatusCode" : 200,
"MemoryUsedPercentage" : 5.5200005,
"MemoryUsed" : 0.0,
"TaskRunning" : 3,
"DiskUsed" : 92.0647,
"MemoryTotal" : 0.0,
"CpuTotal" : 1.7
},
"httpStatusCode" : "200",
"requestId" : "E2E2AD3E-B7A4-106C-9063-****",
"successResponse" : true
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | Throttling.User | Request was denied due to user flow control. | The number of requests reached the limit and the request was rejected. Try again later. |
500 | ServiceUnavailable | The request has failed due to a temporary failure of the server. | The response of the server timed out or the server was unavailable. Try again. If the error persists, contact technical support. |
403 | InvalidSecurityToken.Expired | Specified SecurityToken is expired. | The signature expired. Use a new signature. |
For a list of error codes, see Service error codes.