Creates an isolation rule.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
mse:CreateIsolationRule |
create |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| Namespace |
string |
Yes |
The microservice namespace to which the application belongs. |
default |
| AppName |
string |
Yes |
The application name. |
spring-cloud-a |
| Threshold |
number |
Yes |
The concurrency threshold for isolation rules. |
3 |
| Enable |
boolean |
Yes |
Specifies whether to enable the rule. |
true |
| Resource |
string |
Yes |
The name of the interface to which the rule is applicable. The interface name must be the same as the name on the interface details page in the console. |
/a |
| AppId |
string |
No |
The application ID. |
hkhon1po62@c3df23522bXXXXX |
| RegionId |
string |
No |
The region in which the cluster resides. |
cn-hangzhou |
| LimitApp |
string |
No |
||
| AcceptLanguage |
string |
No |
The language in which you want the results to be displayed. Valid values: zh (default): Chinese. en: English. |
zh |
Response elements
|
Parameter |
Type |
Description |
Example |
|
object |
|||
| Message |
string |
The response message. |
OK |
| RequestId |
string |
The request ID. |
4E9FDCFE-0738-493B-B801-82BDFBCB**** |
| Code |
string |
The response code. |
200 |
| Data |
object |
The details of the rule. |
|
| Namespace |
string |
The microservice namespace to which the application belongs. |
default |
| Id |
integer |
The rule ID. |
1 |
| AppName |
string |
The application name. |
spring-cloud-a |
| Resource |
string |
The name of the interface to which the rule applies. The interface name must be the same as that displayed on the API Details page in the console. |
/a |
| Threshold |
number |
The concurrency threshold for isolation rules. |
3 |
| Enable |
boolean |
Indicates whether the rule is enabled. |
true |
| AppId |
string |
The application ID. |
hpn9ac29kz@e31a4b871****** |
| RegionId |
string |
The region in which the cluster resides. |
cn-hangzhou |
| LimitApp |
string |
||
| Success |
boolean |
The result of the request. |
true |
Examples
Success response
JSON format
{
"Message": "OK",
"RequestId": "4E9FDCFE-0738-493B-B801-82BDFBCB****",
"Code": "200",
"Data": {
"Namespace": "default",
"Id": 1,
"AppName": "spring-cloud-a",
"Resource": "/a",
"Threshold": 3,
"Enable": true,
"AppId": "hpn9ac29kz@e31a4b871******",
"RegionId": "cn-hangzhou",
"LimitApp": ""
},
"Success": true
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | IllegalRequest | Invalid request:%s | Invalid request: %s |
| 400 | InvalidParameter | Parameter error:%s | Request parameter error: %s |
| 500 | InternalError | Console error. Try again later:%s | Console error. Try again later: %s |
| 403 | NoPermission | You are not authorized to perform this operation:%s | You do not have the permission to use this interface:%s |
| 404 | NotFound | Not found:%s | The resource does not exist:%s |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.