Changes the node specifications of a specified PolarDB cluster.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ModifyDBNodesClass

The operation that you want to perform. Set the value to ModifyDBNodesClass.

DBClusterId String Yes pc-*************

The ID of the cluster.

ModifyType String Yes Upgrade

The type of the configuration change. Valid values:

  • Upgrade
  • Downgrade
ClientToken String No 6000170000591aed949d0f54a343f1a4233c1e7d1c5c******

The client token that is used to ensure the idempotence of the request. You can use the client to generate the value, but you must ensure that it is unique among different requests. The token can only contain ASCII characters and cannot exceed 64 characters in length. The token is case-sensitive.

PlannedStartTime String No 2021-01-14T09:00:00Z

The earliest time to upgrade the specifications within the scheduled time period. Specify the time in the YYYY-MM-DDThh:mm:ssZ format. The time must be in UTC.

Note
  • This parameter takes effect only when ModifyType is set to Upgrade.
  • The earliest start time of the task can be a point in time within the next 24 hours. For example, if the current time is 2021-01-14T09:00:00Z, you can specify a point in the time range from 2021-01-14T09:00:00Z to 2021-01-15T09:00:00Z.
  • If this parameter is empty, the upgrade task is immediately performed.
PlannedEndTime String No 2021-01-14T09:30:00Z

The lastest time to upgrade the specifications within the scheduled time period. Specify the time in the YYYY-MM-DDThh:mm:ssZ format. The time must be in UTC.

Note
  • The value of this parameter must be at least 30 minutes later than the value of the PlannedStartTime parameter.
  • If you specify the PlannedStartTime parameter but do not specify a value for the PlannedEndTime parameter, the latest start time of the task is set to a value that is calculated by the value of the PlannedEndTime parameter + 30 minutes by default. For example, if you set the PlannedStartTime parameter to 2021-01-14T09:00:00Z and you do not specify the PlannedEndTime parameter, the latest start time of the task is set to 2021-01-14T09:30:00Z.
SubCategory String No normal_general

The category of the cluster. Valid values:

  • normal_exclusive: dedicated
  • normal_general: genera-purpose
DBNode.N.DBNodeId String No pi-*************

The ID of the cluster node.

Note If you specify this parameter, DBNode.N.TargetClass is required. N is an integer that starts from 1. The maximum value of N is equal to 16 minus the number of existing nodes.
DBNode.N.TargetClass String No polar.mysql.x4.medium

The modified specifications of the node. For more information, see Specifications of compute nodes.

Note If you specify this parameter, DBNode.N.DBNodeId is required. N is an integer that starts from 1. The maximum value of N is equal to 16 minus the number of existing nodes.

Response parameters

Parameter Type Example Description
RequestId String 685F028C-4FCD-407D-A559-072D63******

The ID of the request.

DBClusterId String pc-*************

The ID of the cluster.

OrderId String 2035629******

The ID of the order.

Examples

Sample requests

http(s)://polardb.aliyuncs.com/?Action=ModifyDBNodesClass
&DBClusterId=pc-*************
&ModifyType=Upgrade
&DBNode=[{"DBNodeId":"pi-*************","TargetClass":"polar.mysql.x4.medium"}]
&ClientToken=6000170000591aed949d0f54a343f1a4233c1e7d1c5c******
&PlannedStartTime=2021-01-14T09:00:00Z
&PlannedEndTime=2021-01-14T09:30:00Z
&<Common request parameters>

Sample responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<ModifyDBNodesClassResponse>
    <RequestId>685F028C-4FCD-407D-A559-072D63******</RequestId>
    <DBClusterId>pc-*************</DBClusterId>
    <OrderId>2035629******</OrderId>
</ModifyDBNodesClassResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "685F028C-4FCD-407D-A559-072D63******",
  "DBClusterId" : "pc-*************",
  "OrderId" : "2035629******"
}

Error codes

For a list of error codes, visit the API Error Center.