Upgrades the versions of cluster component instances so that you can benefit from the feature optimizations in the new versions.
Operation description
Upgrading cluster component instance versions may affect your business. Assess the impact before performing the upgrade during off-peak hours, and back up relevant data in advance.
Before upgrading a component, refer to Component release notes to learn about the changes and their impact for the specified component.
Upgrade components one at a time. Confirm that one component has been successfully upgraded before upgrading the next.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
cs:UpgradeK8sComponents |
update |
*Cluster
|
None | None |
Request syntax
POST /clusters/{ClusterId}/components/upgrade HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| ClusterId |
string |
Yes |
The cluster ID. |
cf4299b79b3e34226abfdc80a4bda**** |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| body |
array<object> |
No |
The request parameters. |
|
|
object |
No |
The component information. |
||
| component_name |
string |
Yes |
The component name. |
coredns |
| config |
string |
No |
The custom component parameters, encoded as a JSON string. |
{"CpuRequest":"800m"} |
| next_version |
string |
Yes |
The target version to upgrade to. You can call the |
v1.11.3.5-5321daf49-aliyun |
| policy |
string |
No |
The component upgrade policy. Valid values:
|
canary |
| version |
string |
No |
The current component version. |
v1.11.3.2-f57ea7ed6-aliyun |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| cluster_id |
string |
The cluster ID. |
cf4299b79b3e34226abfdc80a4bda**** |
| request_id |
string |
The request ID. |
bfd12953-31cb-42f1-8a36-7b80ec34**** |
| task_id |
string |
The task ID. |
T-62a944794ee141074400**** |
Examples
Success response
JSON format
{
"cluster_id": "cf4299b79b3e34226abfdc80a4bda****",
"request_id": "bfd12953-31cb-42f1-8a36-7b80ec34****",
"task_id": "T-62a944794ee141074400****"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | AddonPreviewUnsupported | upgrade preview is not supported for component |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.