Deletes a Message Queue for Apache RocketMQ instance.
Usage notes
You can call this operation when you need to deallocate resources. For example, after you unpublish an application, you can deallocate the resources that were used for the application.
An instance can be deleted only when the instance does not contain topics and groups.
QPS limit
Each Alibaba Cloud account can call this operation up to 10 times per second. If the number of requests that you send each second to call this operation exceeds the queries per second (QPS) limit, throttling is triggered. This may interrupt your business. For more information, see QPS limits.
Authorization
By default, only Alibaba Cloud accounts can call this operation. A Resource Access Management (RAM) user can call this operation only after the RAM user is granted the required permissions. The following table describes the permissions that are required to call this operation. For more information, see Policies and examples.
API |
Action |
Resource |
---|---|---|
OnsInstanceDelete |
mq:QueryInstanceBaseInfo mq:DeleteInstance |
acs:mq:*:*:{instanceId} |
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | OnsInstanceDelete |
The operation that you want to perform. Set the value to OnsInstanceDelete. |
InstanceId | String | Yes | MQ_INST_188077086902****_BXSuW61e |
The ID of the instance. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | A07E3902-B92E-44A6-B6C5-6AA111111**** |
The ID of the request. This parameter is a common parameter. Each request has a unique ID. You can use this ID to troubleshoot issues. |
Examples
Sample requests
http(s)://ons.cn-hangzhou.aliyuncs.com/?Action=OnsInstanceDelete
&InstanceId=MQ_INST_188077086902****_BXSuW61e
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<OnsInstanceDeleteResponse>
<RequestId>A07E3902-B92E-44A6-B6C5-6AA111111****</RequestId>
</OnsInstanceDeleteResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "A07E3902-B92E-44A6-B6C5-6AA111111****"
}
Error codes
For a list of error codes, visit the API Error Center.
Delete an instance by using the console
Besides calling the OnsInstanceDelete operation, you can use the Message Queue for Apache RocketMQ console to delete an instance. For information about how to use the Message Queue for Apache RocketMQ console to delete an instance, see Manage instances.