Modifies the specifications or storage space of an ApsaraDB for MongoDB standalone, replica set, or serverless instance. Serverless instances are available only on the China site (aliyun.com).
Operation description
Before you call this operation, make sure that you understand the billing methods and pricing of ApsaraDB for MongoDB.
This operation applies only to standalone and replica set instances. To modify the specifications of sharded cluster instances, you can call the ModifyNodeSpec , CreateNode , DeleteNode , or ModifyNodeSpecBatch operation.
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
dds:ModifyDBInstanceSpec | update |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
DBInstanceId | string | Yes | The ID of the instance. | dds-bp1ea17b41ab**** |
DBInstanceClass | string | No | The instance type. For more information, see Instance types. You can also call the DescribeAvailableResource operation to view instance types. Note
You must specify at least one of the DBInstanceClass and DBInstanceStorage parameters.
| dds.sn4.xlarge.1 |
DBInstanceStorage | string | No | The storage capacity of the instance. Valid values: 10 to 3000. The value must be a multiple of 10. Unit: GB. The values that can be specified for this parameter are subject to the instance types. For more information, see Instance types. Note
| 50 |
OrderType | string | No | The type of the configuration change. Valid values:
Note
This parameter can be configured only when the billing method of the instance is subscription.
| UPGRADE |
AutoPay | boolean | No | Specifies whether to enable automatic payment. Valid values:
| true |
BusinessInfo | string | No | The business information. | {“ActivityId":"000000000"} |
ReplicationFactor | string | No | The number of nodes in the instance.
Note
This parameter is not required for a serverless instance which is only available on the China site (aliyun.com).
| 3 |
ReadonlyReplicas | string | No | The number of read-only nodes. Valid values: 0 to 5. If your instance has only Classic Network and VPC endpoints, you must apply for a public endpoint or release the classic network endpoint for the instance before you can change the Read-only Nodes value. Note
You can go to the Database Connections page to view the types of networks that are enabled.
| 1 |
CouponNo | string | No | The coupon code. Default value: | youhuiquan_promotion_option_id_for_blank |
EffectiveTime | string | No | The time when the changed configurations take effect. Valid values:
| Immediately |
ExtraParam | string | No | The additional parameter. Valid values:
| async |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "1E9F1104-19E7-59F0-AB7F-F4EBFDEA****",
"OrderId": "21012408824****"
}
Error codes
HTTP status code | Error code | Error message |
---|---|---|
400 | MissingParameter | The input parameters DBInstanceClass and DBInstanceStorage all blank or no change. |
400 | InvalidDBInstanceClass.ValueNotSupported | The specified parameter DBInstanceClass is not valid. |
400 | InvalidDBInstanceStorage.ValueNotSupported | The specified parameter DBInstanceStorage is not valid. |
400 | LX_REQUEST_TOKEN_CONFLICT | The request token is conflict. |
400 | TradeConfirmPayError | BIZ_ERROR - degrade refund error |
400 | PRICE.ORIGIN_PRICE_ERROR | Origin lingxiao price request error. |
403 | OperationDenied | The resource is out of usage. |
403 | InvaildDBInstanceClassInRegion.NotAvailable | The DBInstanceClass in the Region is not available. |
404 | InvalidDBInstanceId.NotFound | The DBInstanceId provided does not exist in our records. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2024-01-12 | The Error code has changed | View Change Details |