All Products
Search
Document Center

Auto Scaling:DescribeScalingGroups

Last Updated:Sep 17, 2026

Queries scaling groups. You can call this operation to view basic information about scaling groups, instances in scaling groups, and scaling configurations.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

ess:DescribeScalingGroups

get

*ScalingGroup

acs:ess:{#regionId}:{#accountId}:scalinggroup/{#ScalingGroupId}

None None

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

Yes

The region ID of the scaling group.

cn-qingdao

PageNumber

integer

No

The page number of the scaling group list. Minimum value: 1.

Default value: 1.

1

PageSize

integer

No

The number of entries per page when you use paging. Maximum value: 50.

Default value: 10.

Valid values:

  • 10 :

    10

10

ScalingGroupName

string

No

The name of the scaling group.

scalinggroup****

ScalingGroupName.1

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.2

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.3

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.4

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.5

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.6

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.7

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.8

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.9

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.10

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.11

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.12

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.13

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.14

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.15

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.16

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.17

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.18

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.19

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

ScalingGroupName.20

string

No

The name of scaling group N that you want to query. Invalid scaling group names are ignored and no error is returned.

scalinggroup****

GroupType

string

No

The type of instances managed by the scaling group. Valid values:

  • ECS: ECS instances are managed by the scaling group.

  • ECI: ECI instances are managed by the scaling group.

ECS

ScalingGroupId

array

No

The ID of scaling group N that you want to query. Valid values of N: 1 to 20. Invalid scaling group IDs are ignored and no error is returned.

asg-bp14wlu85wrpchm0****

string

No

The ID of scaling group N that you want to query. Valid values of N: 1 to 20. Invalid scaling group IDs are ignored and no error is returned.

asg-bp14wlu85wrpchm0****

ResourceGroupId

string

No

The ID of the resource group to which the scaling group belongs.

Note

If no scaling group belongs to the specified resource group, an empty result is returned and no error is reported.

rg-123****

Tag

array<object>

No

The tags of the scaling group.

object

No

The tags of the scaling group.

Key

string

No

The tag key of the scaling group.

Department

Value

string

No

The tag value of the scaling group.

Finance

Response elements

Element

Type

Description

Example

object

RequestId

string

The request ID.

473469C7-AA6F-4DC5-B3DB-A3DC0DE3****

PageNumber

integer

The page number of the current page.

1

PageSize

integer

The number of entries per page.

10

TotalCount

integer

The total number of scaling groups.

1

ScalingGroups

object

ScalingGroup

array<object>

The collection of scaling group information.

array<object>

The collection of scaling group information.

VpcId

string

The ID of the VPC to which the scaling group belongs.

vpc-bp1vwnn14rqpyiczj****

CreationTime

string

The time when the scaling group was created.

2014-08-14T10:58Z

TotalInstanceCount

integer

The total number of ECS instances in the scaling group.

1

ScalingGroupName

string

The name of the scaling group.

dyrSuvBOtO1dEdIlIbp****

SpotInstancePools

integer

The number of available instance types. The scaling group creates spot instances in a cost-effective manner across the specified instance types. Valid values: 0 to 10.

When MultiAZPolicy is set to COMPOSABLE, the default value is 2.

5

StoppedCapacity

integer

The number of instances that are in the economical mode (stopped) in the scaling group.

1

OnDemandPercentageAboveBaseCapacity

integer

The percentage of pay-as-you-go instances among the excess instances when the minimum number of pay-as-you-go instances (OnDemandBaseCapacity) is met. Valid values: 0 to 100.

When MultiAZPolicy is set to COMPOSABLE, the default value is 100.

20

ModificationTime

string

The time when the scaling group was last modified.

2014-08-14T10:58Z

MinSize

integer

The minimum number of ECS instances in the scaling group.

1

ScalingGroupId

string

The ID of the scaling group.

asg-bp14wlu85wrpchm0****

CompensateWithOnDemand

boolean

When MultiAZPolicy is set to COST_OPTIMIZED, specifies whether to automatically create pay-as-you-ECS instances when spot instances cannot be created due to reasons such as cost or insufficient inventory. Valid values:

  • true: Pay-as-you-ECS instances can be created.

  • false: Pay-as-you-ECS instances cannot be created.

true

ScalingPolicy

string

The reclaim mode of the scaling group. Valid values:

  • recycle: The scaling group uses the shutdown and reclaim mode.

  • release: The scaling group uses the release mode.

  • forcerelease: The scaling group uses the forced release mode.

For more information about the actions on removed instances, see RemoveInstances.

recycle

RemovingWaitCapacity

integer

The number of ECS instances that are in the pending remove state in the scaling group.

1

ActiveCapacity

integer

The number of ECS instances that have been added to the scaling group and are running as expected.

1

OnDemandBaseCapacity

integer

The minimum number of pay-as-you-go instances required in the scaling group. Valid values: 0 to 1000. When the number of pay-as-you-go instances in the scaling group is less than this value, the system preferentially creates pay-as-you-go instances.

When MultiAZPolicy is set to COMPOSABLE, the default value is 0.

30

ProtectedCapacity

integer

The number of ECS instances that are in the protected state in the scaling group.

1

HealthCheckType

string

The health check mode of the scaling group. Valid values:

  • NONE: No health check is performed.

  • ECS: Health checks are performed on ECS instances in the scaling group. This value is used to enable instance health checks for both ECS-type and ECI-type scaling groups.

  • LOAD_BALANCER: The instance health status is determined based on the health check results of load balancing. CLB-type load balancing is not supported.

ECS

LifecycleState

string

The status of the scaling group. Valid values:

  • Active: The scaling group is active. Active scaling groups can accept requests to execute scaling rules and trigger scaling activities.

  • Inactive: The scaling group is inactive. Inactive scaling groups do not accept requests to execute scaling rules.

  • Deleting: The scaling group is being deleted. Scaling groups that are being deleted do not accept requests to execute scaling rules, and the scaling group parameters cannot be modified.

Active

GroupDeletionProtection

boolean

Indicates whether deletion protection is enabled for the scaling group. Valid values:

  • true: Deletion protection is enabled. The scaling group cannot be deleted.

  • false: Deletion protection is disabled.

true

ActiveScalingConfigurationId

string

The ID of the active scaling configuration in the scaling group.

asc-bp1et2qekq3ojr33****

GroupType

string

The type of instances managed by the scaling group.

ECS

MultiAZPolicy

string

The scaling policy for ECS instances in a multi-zone scaling group. Valid values:

  • PRIORITY: ECS instances are scaled based on the vSwitches you specified (VSwitchIds.N). When an ECS instance cannot be created in the zone of the vSwitch with the highest priority, the system uses the vSwitch with the next highest priority to create the ECS instance.

  • COST_OPTIMIZED: ECS instances are created based on the unit vCPU price in ascending order. When the scaling configuration specifies multiple instance types with the spot billing method, spot instances are preferentially created. You can use the CompensateWithOnDemand parameter to specify whether to automatically create pay-as-you-go instances when spot instances cannot be created due to insufficient inventory.

    Note

    COST_OPTIMIZED takes effect only when multiple instance types are specified in the scaling configuration or spot instances are used.

  • BALANCE: ECS instances are evenly distributed across the zones specified for the scaling group. If instances become unevenly distributed across zones due to reasons such as insufficient inventory, you can call the RebalanceInstance operation to rebalance resources.

  • COMPOSABLE: A composite policy that allows you to customize a combination of the preceding multi-zone scaling policies for ECS instances. Settings for scale-in and scale-out can be configured separately. You can allocate instances based on different billable methods across active zones.

PRIORITY

RemovingCapacity

integer

The number of ECS instances that are being removed from the scaling group.

0

PendingWaitCapacity

integer

The number of ECS instances that are in the pending add state in the scaling group.

1

StandbyCapacity

integer

The number of instances that are in the standby state in the scaling group.

1

PendingCapacity

integer

The number of ECS instances that are being added to the scaling group and have not completed the relevant configurations.

0

LaunchTemplateId

string

The ID of the launch template used by the scaling group.

lt-m5e3ofjr1zn1aw7****

TotalCapacity

integer

The total weighted capacity of all ECS instances in the scaling group if instance type weights are configured. Otherwise, the total number of ECS instances in the scaling group.

1

DesiredCapacity

integer

The expected number of instances in the scaling group. The scaling group automatically maintains the number of ECS instances at the expected number of instances.

5

SpotInstanceRemedy

boolean

Indicates whether supplemental spot instances are enabled. When enabled, the scaling group attempts to create new instances to replace spot instances that are about to be reclaimed after a reclamation notification is received.

true

LaunchTemplateVersion

string

The version of the launch template used by the scaling group.

Default

RegionId

string

The ID of the region where the scaling group resides.

cn-qingdao

VSwitchId

string

The ID of the vSwitch associated with the scaling group.

vsw-bp1whw2u46cn8zubm****

MaxSize

integer

The maximum number of ECS instances in the scaling group.

2

DefaultCooldown

integer

The default cooldown time of the scaling group. During the cooldown time, the scaling group does not execute other scaling activities. This parameter applies only to scaling activities triggered by CloudMonitor event-triggered tasks.

60

VServerGroups

object

VServerGroup

array<object>

The list of backend server groups.

array<object>

The list of backend server groups.

LoadBalancerId

string

The ID of the load balancing instance to which the backend server group belongs.

147b46d767c-cn-qingdao-cm5****

VServerGroupAttributes

object

VServerGroupAttribute

array<object>

The attributes of the backend server group.

object

The attributes of the backend server group.

VServerGroupId

string

The ID of the backend server group.

rsp-bp12bjrny****

Weight

integer

The weight of the backend server group.

1

Port

integer

The port number used by the load balancing instance to serve external requests.

22

LaunchTemplateOverrides

object

LaunchTemplateOverride

array<object>

The instance type information that extends the launch template.

object

The instance type information that extends the launch template.

WeightedCapacity

integer

The weight of the instance type, which represents the capacity of a single instance of this type in the scaling group. A higher weight means fewer instances of this type are required to meet the desired capacity.

4

InstanceType

string

The specified instance type, which overrides the instance type in the launch template.

ecs.c5.xlarge

SpotPriceLimit

number

The maximum bid price for the instance type specified in the launch template override (LaunchTemplateOverride.N.InstanceType). You can specify N values for this parameter. The extended launch template supports N instance types. Valid values of N: 1 to 10.

Note

This parameter takes effect only when the LaunchTemplateId parameter specifies a launch template.

0.025

AlbServerGroups

object

AlbServerGroup

array<object>

The collection of ALB server group information.

object

The collection of ALB server group information.

AlbServerGroupId

string

The ID of the ALB server group.

sgp-ddwb0y0g6y9bjm****

Weight

integer

The weight of the ECS instance as a backend server after Auto Scaling adds the ECS instance to the ALB server group.

100

Port

integer

The port number used by the ECS instance after Auto Scaling adds the ECS instance to the ALB server group.

80

ServerGroups

object

ServerGroup

array<object>

The collection of load balancing server group information.

Note

You can use this parameter to obtain information about ALB-type, NLB-type, and GWLB-type server groups associated with the scaling group.

object

The collection of load balancing server group information.

ServerGroupId

string

The ID of the server group.

sgp-i9ouakeaerr*****

Type

string

The type of the server group. Valid values:

  • ALB: Application Load Balancer (ALB).

  • NLB: Network Load Balancer (NLB).

  • GWLB: Gateway Load Balancer (GWLB).

ALB

Weight

integer

The weight of the ECS instance as a backend server after Auto Scaling adds the ECS instance to the server group.

100

Port

integer

The port number used by the ECS instance after Auto Scaling adds the ECS instance to the server group.

80

RemovalPolicies

object

RemovalPolicy

array

The collection of scale-in policies for ECS instances. Valid values:

  • OldestInstance: The earliest created ECS instance is removed.

  • NewestInstance: The most recently created ECS instance is removed.

  • OldestScalingConfiguration: The ECS instance created from the earliest scaling configuration is removed.

  • CustomPolicy: ECS instances are removed based on a custom scale-in policy defined by a Function Compute function.

string

The collection of scale-in policies for ECS instances. Valid values:

  • OldestInstance: The earliest created ECS instance is removed.

  • NewestInstance: The most recently created ECS instance is removed.

  • OldestScalingConfiguration: The ECS instance created from the earliest scaling configuration is removed.

  • CustomPolicy: ECS instances are removed based on a custom scale-in policy defined by a Function Compute function.

OldestScalingConfiguration

DBInstanceIds

object

DBInstanceId

array

The ID of the ApsaraDB RDS instance associated with the scaling group.

string

The ID of the ApsaraDB RDS instance associated with the scaling group.

rm-bp15556qzebg1****

LoadBalancerIds

object

LoadBalancerId

array

The list of IDs of the load balancing instances associated with the scaling group.

string

The list of IDs of the load balancing instances associated with the scaling group.

lb-bp19byhscefk3x0li****

VSwitchIds

object

VSwitchId

array

The collection of vSwitch IDs associated with the scaling group. If you specified the VSwitchIds parameter, the VSwitchId parameter is ignored.

string

The collection of vSwitch IDs associated with the scaling group. If you specified the VSwitchIds parameter, the VSwitchId parameter is ignored.

vsw-bp1whw2u46cn8zubm****

SuspendedProcesses

object

SuspendedProcess

array

The suspended scaling process. If no process is suspended, an empty value is returned. Valid values:

  • ScaleIn: scale-in process.

  • ScaleOut: scale-out process.

  • HealthCheck: health check.

  • AlarmNotification: event-triggered task.

  • ScheduledAction: scheduled task.

string

The suspended scaling process. If no process is suspended, an empty value is returned. Valid values:

  • ScaleIn: scale-in process.

  • ScaleOut: scale-out process.

  • HealthCheck: health check.

  • AlarmNotification: event-triggered task.

  • ScheduledAction: scheduled task.

ScaleIn

SystemSuspended

boolean

Indicates whether Auto Scaling has stopped executing scaling activities in the scaling group. Valid values:

  • true: Auto Scaling has stopped executing scaling activities. This indicates that the scaling group has experienced continuous scale-in or scale-out failures for more than 7 days. Modify the scaling group or scaling configuration to resume the execution of scaling activities.

  • false: Scaling activities are being executed in the scaling group.

true

MonitorGroupId

string

The ID of the CloudMonitor application group associated with the scaling group.

1497****

AzBalance

boolean

Indicates whether the capacity of the scaling group is evenly distributed across multiple zones. Valid values:

  • true: The capacity is evenly distributed across multiple zones.

  • false: The capacity is not evenly distributed across multiple zones.

Note

This parameter takes effect only when MultiAZPolicy is set to COMPOSABLE.

false

AllocationStrategy

string

The capacity allocation strategy that determines how the scaling group selects available instance types to meet the capacity requirements. The capacity allocation strategy applies to both pay-as-you-go and spot capacities. Valid values:

  • priority: Instances are created based on the order of configured instance types.

  • lowestPrice: Instances are created based on the unit vCPU price of instance types in ascending order.

Note

This parameter takes effect only when MultiAZPolicy is set to COMPOSABLE.

priority

SpotAllocationStrategy

string

The allocation strategy for spot capacity. You can use this parameter to separately specify the allocation strategy for spot capacity. This parameter takes effect only when MultiAZPolicy is set to COMPOSABLE. Valid values:

  • priority: Instances are created based on the order of configured instance types.

  • lowestPrice: Instances are created based on the unit vCPU price of instance types in ascending order.

lowestPrice

MaxInstanceLifetime

integer

The maximum amount of time that an instance can stay in the scaling group. Unit: seconds.

Valid values: 0 or [86400, Integer.maxValue]. A value of 0 clears the previously set MaxInstanceLifetime value (meaning MaxInstanceLifetime is not set).

Default value: null.

Note

This parameter is not supported for Elastic Container Instance (ECI)-type scaling groups or scaling groups with the No Fees for Stopped Instances feature enabled.

null

CustomPolicyARN

string

The Alibaba Cloud Resource Name (ARN) of the China Chinese function for the custom scale-in policy. This parameter takes effect only when the first removal policy in RemovalPolicies is set to CustomPolicy.

acs:fc:cn-zhangjiakou:16145688****:services/ess_custom_terminate_policy.LATEST/functions/ess_custom_terminate_policy_name

InitCapacity

integer

The number of instances that are in the Initializing state before scale-out in the scaling group.

0

ResourceGroupId

string

The ID of the resource group to which the scaling group belongs.

rg-123****

LoadBalancerConfigs

object

LoadBalancerConfig

array<object>

The load balancing configurations of Classic Load Balancer (CLB, formerly SLB) instances.

object

The load balancing configurations of Classic Load Balancer (CLB, formerly SLB) instances.

LoadBalancerId

string

The ID of the load balancing CLB (formerly SLB) instance.

147b46d767c-cn-qingdao-cm5****

Weight

integer

The weight of the ECS instance as a backend server after Auto Scaling adds the ECS instance to the load balancing CLB (formerly SLB) server group. A higher weight indicates that the ECS instance receives more access requests. If the weight is 0, the ECS instance does not receive any access requests. The system allocates access requests based on the weight.

Valid values: 0 to 100.

10

EnableDesiredCapacity

boolean

Indicates whether the expected number of instances feature is enabled. Valid values:

  • true: Enabled. The expected number of instances information is returned when you query the scaling group.

  • false: Not enabled. The expected number of instances information is not returned when you query the scaling group.

false

Tags

object

Tag

array<object>

The tags of the scaling group.

object

The tags of the scaling group.

TagKey

string

The tag key of the scaling group.

Department

TagValue

string

The tag value of the scaling group.

Finance

Propagate

boolean

Indicates whether the tag is a propagatable tag. Valid values:

  • true: The tag on the scaling group is propagated only to newly created instances and not to instances that are already running in the scaling group.

  • false: The tag on the scaling group is not propagated to instances.

Default value: false.

false

HealthCheckTypes

object

HealthCheckType

array

The health check mode of the scaling group. Valid values:

  • NONE: No health check is performed.

  • ECS: Health checks are performed on instances in the scaling group. This value is used to enable instance health checks for both ECS-type and ECI-type scaling groups.

  • LOAD_BALANCER: The health status of instances is determined based on load balancing health check results. CLB-type load balancing is not supported.

string

The health check mode of the scaling group. Valid values:

  • NONE: No health check is performed.

  • ECS: Health checks are performed on instances in the scaling group. This value is used to enable instance health checks for both ECS-type and ECI-type scaling groups.

  • LOAD_BALANCER: The health status of instances is determined based on load balancing health check results. CLB-type load balancing is not supported.

ECS

DBInstances

object

DBInstance

array<object>

The list of databases associated with the scaling group.

array<object>

The configuration information of the database associated with the scaling group.

DBInstanceId

string

The database instance ID.

rm-m5eqju85s45mu0***

Type

string

The database type. Valid values:

  • RDS.

  • Redis.

  • MongoDB.

RDS

SecurityGroupIds

object

SecurityGroupId

array

The list of security groups that the scaling group adds to the database security group whitelist.

string

Indicates whether the scaling group removes the security groups in the associated database list from the database security group whitelist. This parameter is valid for the associated database list when the AttachMode parameter in the CreateScalingGroup operation is set to SecurityGroup. Valid values:

  • true: The security groups in this list are removed from the database security group whitelist.

  • false: The security groups in this list are not removed from the database security group whitelist.

sg-uf65zt66cf2a0q47***

SpotCapacity

integer

The number of spot instances in the scaling group.

0

StopInstanceTimeout

integer

The timeout period for waiting for an ECS instance to stop during the scale-in process. Unit: seconds.

60

CapacityOptions

object

The capacity options.

OnDemandBaseCapacity

integer

The minimum number of pay-as-you-go instances required in the scaling group. When the number of pay-as-you-go instances in the scaling group is less than this value, the system preferentially creates pay-as-you-go instances. Valid values: 0 to 1000.

0

OnDemandPercentageAboveBaseCapacity

integer

The percentage of pay-as-you-go instances among the excess instances after the minimum number of pay-as-you-go instances specified by OnDemandBaseCapacity is met. Valid values: 0 to 100.

0

CompensateWithOnDemand

boolean

When MultiAZPolicy is set to COST_OPTIMIZED, specifies whether to automatically create pay-as-you-ECS instances when spot instances cannot be created due to reasons such as cost or insufficient inventory. Valid values:

  • true: Pay-as-you-ECS instances can be created.

  • false: Pay-as-you-ECS instances cannot be created.

true

SpotAutoReplaceOnDemand

boolean

When CompensateWithOnDemand is enabled, if the pay-as-you-go ratio exceeds the OnDemandPercentageAboveBaseCapacity ratio, the system attempts to replace pay-as-you-go capacity with spot instances. A common scenario is when CompensateWithOnDemand causes spot instances to be downgraded to pay-as-you-go instances due to spot inventory or pricing issues. To prevent pay-as-you-go instances from persisting for an extended period, the system attempts to replace the excess pay-as-you-go capacity with spot instances. Valid values:

  • true: Allowed.

  • false: Not allowed.

false

PriceComparisonMode

string

The price comparison mode for the cost optimization strategy of the scaling group. Valid values:

  • PricePerUnit: Compares prices based on the price per unit of capacity.

    The capacity of an instance in the scaling group equals the weight configured for the instance type. The default weight is 1, meaning one ECS instance occupies a capacity of 1.

  • PricePerVCpu: Compares prices based on the price per vCPU.

Default value: PricePerUnit.

PricePerUnit

BalanceMode

string

The zone balancing mode. This parameter takes effect only when zone balancing is enabled. Valid values:

  • BalancedBestEffort: When resource creation fails in a zone, the system falls back to other zones to ensure best-effort resource delivery.

  • BalancedOnly: When resource creation fails in a zone, the system does not fall back to other zones. The scaling activity partially succeeds to prevent excessive imbalance of resources across zones.

BalancedBestEffort

AutoRebalance

boolean

Indicates whether auto-rebalancing is enabled for the scaling group. This parameter takes effect only when BalancedOnly is enabled for a zone-balanced scaling group. Valid values:

  • false: Auto-rebalancing is not enabled for the scaling group.

  • true: When auto-rebalancing is enabled, the scaling group automatically detects the capacity across zones. When zone capacity is imbalanced, the scaling group proactively performs scale-out and scale-in operations across zones to rebalance zone capacity.

false

Examples

Success response

JSON format

{
  "RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3****",
  "PageNumber": 1,
  "PageSize": 10,
  "TotalCount": 1,
  "ScalingGroups": {
    "ScalingGroup": [
      {
        "VpcId": "vpc-bp1vwnn14rqpyiczj****",
        "CreationTime": "2014-08-14T10:58Z",
        "TotalInstanceCount": 1,
        "ScalingGroupName": "dyrSuvBOtO1dEdIlIbp****",
        "SpotInstancePools": 5,
        "StoppedCapacity": 1,
        "OnDemandPercentageAboveBaseCapacity": 20,
        "ModificationTime": "2014-08-14T10:58Z",
        "MinSize": 1,
        "ScalingGroupId": "asg-bp14wlu85wrpchm0****",
        "CompensateWithOnDemand": true,
        "ScalingPolicy": "recycle",
        "RemovingWaitCapacity": 1,
        "ActiveCapacity": 1,
        "OnDemandBaseCapacity": 30,
        "ProtectedCapacity": 1,
        "HealthCheckType": "ECS",
        "LifecycleState": "Active",
        "GroupDeletionProtection": true,
        "ActiveScalingConfigurationId": "asc-bp1et2qekq3ojr33****",
        "GroupType": "ECS",
        "MultiAZPolicy": "PRIORITY",
        "RemovingCapacity": 0,
        "PendingWaitCapacity": 1,
        "StandbyCapacity": 1,
        "PendingCapacity": 0,
        "LaunchTemplateId": "lt-m5e3ofjr1zn1aw7****",
        "TotalCapacity": 1,
        "DesiredCapacity": 5,
        "SpotInstanceRemedy": true,
        "LaunchTemplateVersion": "Default",
        "RegionId": "cn-qingdao",
        "VSwitchId": "vsw-bp1whw2u46cn8zubm****",
        "MaxSize": 2,
        "DefaultCooldown": 60,
        "VServerGroups": {
          "VServerGroup": [
            {
              "LoadBalancerId": "147b46d767c-cn-qingdao-cm5****",
              "VServerGroupAttributes": {
                "VServerGroupAttribute": [
                  {
                    "VServerGroupId": "rsp-bp12bjrny****",
                    "Weight": 1,
                    "Port": 22
                  }
                ]
              }
            }
          ]
        },
        "LaunchTemplateOverrides": {
          "LaunchTemplateOverride": [
            {
              "WeightedCapacity": 4,
              "InstanceType": "ecs.c5.xlarge",
              "SpotPriceLimit": 0.025
            }
          ]
        },
        "AlbServerGroups": {
          "AlbServerGroup": [
            {
              "AlbServerGroupId": "sgp-ddwb0y0g6y9bjm****",
              "Weight": 100,
              "Port": 80
            }
          ]
        },
        "ServerGroups": {
          "ServerGroup": [
            {
              "ServerGroupId": "sgp-i9ouakeaerr*****",
              "Type": "ALB",
              "Weight": 100,
              "Port": 80
            }
          ]
        },
        "RemovalPolicies": {
          "RemovalPolicy": [
            "OldestScalingConfiguration"
          ]
        },
        "DBInstanceIds": {
          "DBInstanceId": [
            "rm-bp15556qzebg1****"
          ]
        },
        "LoadBalancerIds": {
          "LoadBalancerId": [
            "lb-bp19byhscefk3x0li****"
          ]
        },
        "VSwitchIds": {
          "VSwitchId": [
            "vsw-bp1whw2u46cn8zubm****"
          ]
        },
        "SuspendedProcesses": {
          "SuspendedProcess": [
            "ScaleIn"
          ]
        },
        "SystemSuspended": true,
        "MonitorGroupId": "1497****",
        "AzBalance": false,
        "AllocationStrategy": "priority",
        "SpotAllocationStrategy": "lowestPrice",
        "MaxInstanceLifetime": 0,
        "CustomPolicyARN": "acs:fc:cn-zhangjiakou:16145688****:services/ess_custom_terminate_policy.LATEST/functions/ess_custom_terminate_policy_name",
        "InitCapacity": 0,
        "ResourceGroupId": "rg-123****",
        "LoadBalancerConfigs": {
          "LoadBalancerConfig": [
            {
              "LoadBalancerId": "147b46d767c-cn-qingdao-cm5****",
              "Weight": 10
            }
          ]
        },
        "EnableDesiredCapacity": false,
        "Tags": {
          "Tag": [
            {
              "TagKey": "Department",
              "TagValue": "Finance",
              "Propagate": false
            }
          ]
        },
        "HealthCheckTypes": {
          "HealthCheckType": [
            "ECS"
          ]
        },
        "DBInstances": {
          "DBInstance": [
            {
              "DBInstanceId": "rm-m5eqju85s45mu0***",
              "Type": "RDS",
              "SecurityGroupIds": {
                "SecurityGroupId": [
                  "sg-uf65zt66cf2a0q47***"
                ]
              }
            }
          ]
        },
        "SpotCapacity": 0,
        "StopInstanceTimeout": 60,
        "CapacityOptions": {
          "OnDemandBaseCapacity": 0,
          "OnDemandPercentageAboveBaseCapacity": 0,
          "CompensateWithOnDemand": true,
          "SpotAutoReplaceOnDemand": false,
          "PriceComparisonMode": "PricePerUnit"
        },
        "BalanceMode": "BalancedBestEffort",
        "AutoRebalance": false
      }
    ]
  }
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.