1. API Description
Domain name for API request: tke.intl.tencentcloudapi.com.
This API is used to obtain the current progress of node upgrade. If the cluster is not in node upgrade status, the API will report an error: Task not found.
A maximum of 20 requests can be initiated per second for this API.
We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.
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 Params. The value used for this API: GetUpgradeInstanceProgress. |
| Version |
Yes |
String |
Common Params. The value used for this API: 2018-05-25. |
| Region |
Yes |
String |
Common Params. For more information, please see the list of regions supported by the product. |
| ClusterId |
Yes |
String |
Cluster ID |
| Limit |
No |
Integer |
Maximum number of nodes to be queried |
| Offset |
No |
Integer |
The starting node for the query |
3. Output Parameters
| Parameter Name |
Type |
Description |
| Total |
Integer |
Total nodes to upgrade |
| Done |
Integer |
Total upgraded nodes |
| LifeState |
String |
The lifecycle of the upgrade task process: running paused: stopped pausing: stopping done: completed timeout: timed out aborted: canceled |
| Instances |
Array of InstanceUpgradeProgressItem |
Details of upgrade progress of each node |
| ClusterStatus |
InstanceUpgradeClusterStatus |
Current cluster status |
| RequestId |
String |
The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
4. Example
Example1 Querying the upgrade status
This example shows you how to query the upgrade status.
https:
&ClusterId=cls-xxxxxx
&<Common request parameters>
Output Example
{
"Response": {
"Total": 0,
"Done": 0,
"LifeState": "abc",
"Instances": [
{
"InstanceID": "ins-wggphft5",
"LifeState": "paused",
"StartAt": "2021-02-08T16:29:46+08:00",
"EndAt": "2021-02-08T16:39:46+08:00",
"CheckResult": {
"CheckPass": false,
"Items": [
{
"Namespace": "default",
"WorkLoadKind": "ReplicaSet",
"WorkLoadName": "kubernetes-proxy-67fd23cf4d",
"Before": 1,
"After": 0,
"Pods": [
"kubernetes-proxy-67fd23cf4d-2tcxw"
]
}
],
"SinglePods": []
},
"Detail": [
{
"EndAt": null,
"FailedMsg": "precheck failed",
"LifeState": "failed",
"StartAt": "2023-02-08T08:29:51Z",
"Step": "preCheck"
},
{
"EndAt": null,
"FailedMsg": "",
"LifeState": "pending",
"StartAt": null,
"Step": "drain"
},
{
"EndAt": null,
"FailedMsg": "",
"LifeState": "pending",
"StartAt": null,
"Step": "remove"
},
{
"EndAt": null,
"FailedMsg": "",
"LifeState": "pending",
"StartAt": null,
"Step": "reset"
},
{
"EndAt": null,
"FailedMsg": "",
"LifeState": "pending",
"StartAt": null,
"Step": "postCheck"
}
]
}
],
"ClusterStatus": {
"PodTotal": 10,
"NotReadyPod": 0
},
"RequestId": "b224fa4b-fedf-4061-baa9-d547ew858df"
}
}
5. Developer Resources
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.TaskNotFound |
No task found |
| InternalError.UnexpectedInternal |
Unknown internal error. |
| InvalidParameter.Param |
Parameter error. |