CreateScalingRule
Description
create scaling rules.
Request Method
POST
Request Path
/apsara/route/Ess/CreateScalingRule
Request Parameters Common Parameters
Name | Location | Type | Required | Sample value | Description |
---|---|---|---|---|---|
ScalingRuleName | BODY | string | No | No sample value for this parameter. | the display name of the scaling rule, 2-40 English or Chinese characters, starting with numbers, large and small letters or Chinese, and can contain numbers, "_", "-" or "." The same user account is unique in the same region and the same scaling group. If this parameter is not specified, the default value is ScalingRuleId. |
AdjustmentValue | BODY | integer | Yes | No sample value for this parameter. | the adjustment value of the scaling rule. QuantityChangeInCapacity:(0, 100] U (-100, 0] PercentChangeInCapacity:[0, 10000] U [-10000, 0] TotalCapacity:[0, 100] |
regionId | BODY | string | Yes | No sample value for this parameter. | region id |
ScalingGroupId | BODY | string | Yes | No sample value for this parameter. | the ID of the scaling group to which the scaling rule belongs. |
Cooldown | BODY | integer | No | No sample value for this parameter. | cooldown of scaling rules. Value range:[0, 86400], unit: seconds. The default value is: empty. |
version | BODY | string | No | 2016-01-01 | version of api |
AdjustmentType | BODY | string | Yes | No sample value for this parameter. | How to adjust the scaling rule. Optional value: QuantityChangeInCapacity: increase or decrease the specified number of ECS instances. PercentChangeInCapacity: increase or decrease ECS instances with a specified proportion. TotalCapacity: adjusts the number of ECS instances in the current scaling group to the specified number. |
Return data
Name | Type | Sample value | Description |
---|---|---|---|
RequestID | string | 1E3D5A1E0-67CA-43DA-24BC-EAF2D5A1E4DC | Request id |
Example
Successful Response example
{
"RequestID":"1E3D5A1E0-67CA-43DA-24BC-EAF2D5A1E4DC"
}
Failed Response example
{
"errorSample":
{
"resultCode":-1,
"resultMsg":"system error",
"result":null
}
}