Reviewed-by: Ziuzko, Stanislav <stanislav.ziuzko@t-systems.com> Co-authored-by: chenjunjie <chenjunjie@huawei.com> Co-committed-by: chenjunjie <chenjunjie@huawei.com>
9.7 KiB
Changing Instance Specifications
Function
This API is used to change instance specifications.
URI
POST /v2/{project_id}/rocketmq/instances/{instance_id}/extend
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
project_id |
Yes |
String |
Definition Project ID. For details about how to obtain it, see Obtaining a Project ID. Constraints N/A Range N/A Default Value N/A |
instance_id |
Yes |
String |
Definition Instance ID. You can call the API for querying all instances to obtain the instance ID. The instance ID is in the response body. Constraints N/A Range N/A Default Value N/A |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
oper_type |
Yes |
String |
Definition Change type. Constraints N/A Range
Default Value N/A |
new_storage_space |
No |
Integer |
Definition New storage specification Constraints This parameter is valid and mandatory when oper_type is set to storage.
Range N/A Default Value N/A |
new_product_id |
No |
String |
Definition New product ID Constraints
Range N/A Default Value N/A |
publicip_id |
No |
String |
Definition ID of the EIP bound to the instance. Use commas (,) to separate multiple EIP IDs. Constraints This parameter is mandatory when oper_type is horizontal and public access is enabled. Range N/A Default Value N/A |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
|---|---|---|
job_id |
String |
Definition ID of the specification modification task. Constraints N/A Range N/A Default Value N/A |
Example Requests
Increasing an instance flavor
POST https://{endpoint}/v2/{project_id}/rocketmq/instances/{instance_id}/extend { "oper_type" : "horizontal", "new_product_id" : "rocketmq.b2.large.4", "new_storage_space" : 1200 }Expanding instance storage
POST https://{endpoint}/v2/{project_id}/rocketmq/instances/{instance_id}/extend { "oper_type" : "storage", "new_storage_space" : 300 }
Example Responses
Status code: 200
Instance specifications changed.
{
"job_id" : "93b94287-728d-4bb1-a158-cb66cb0854e7"
}
Status Codes
Status Code |
Description |
|---|---|
200 |
Instance specifications changed. |
Error Codes
See Error Codes.