Queries Elastic Compute Units (ECUs) available for scaling out an application in a specified cluster or the cluster where the application is deployed. This operation is applicable to Elastic Compute Service (ECS) clusters.

Terms

  • Namespace: In Enterprise Distributed Application Service (EDAS), it is the logical concept that is used to isolate resources such as clusters, ECS instances, and applications, and microservices published in EDAS. This concept involves the default namespace or custom namespaces. Each region has a default namespace and supports multiple custom namespaces. By default, only the default namespace is available. You do not need to create a custom namespace if you do not want to isolate resources and microservices.
  • ECU: After an ECS instance is imported to a cluster, the instance becomes an ECU.
  • ECC: After you deploy an application to an ECU in a cluster, the ECU becomes an Elastic Compute Container (ECC).

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request headers

This operation uses common request headers, but does not use special request headers. For more information, see Common parameters.

Request syntax

POST /pop/v5/resource/scale_out_ecu_list HTTPS|HTTP

Request parameters

Parameter Type Required Example Description
LogicalRegionId String No cn-beijing:tdy218

The ID of the namespace.

  • The ID of a custom namespace is in the format of region ID:namespace identifier, such as cn-beijing:tdy218.
  • The ID of the default namespace is in the format of region ID, such as cn-beijing.
ClusterId String No 52984524-6d48-4bbd-******************

The ID of the cluster. You want to query the available ECUs in the cluster. Specify at least one of ClusterId and AppId as the query parameter.

AppId String No b93024fd-8a9d-4ef7-99f1-5f0d65cc****

The ID of the application. You want to query the available ECUs in the cluster where the application is deployed. Specify at least one of ClusterId and AppId as the query parameter.

GroupId String No 8123db90-880f-486f-****-****

The ID of the deployment group. You want to query the available ECUs in the cluster where the deployment group is located.

Cpu Integer No 1

The number of CPU cores based on which you want to query the available ECUs in the cluster.

Mem Integer No 200

The size of available memory based on which you want to query the available ECUs in the cluster. Unit: MB.

InstanceNum Integer No 1

The specified number of ECUs that you want to query. If this parameter is not specified, all the ECUs that meet the query conditions are returned.

Response parameters

Parameter Type Example Description
Code Integer 200

The HTTP status code returned for the request.

EcuInfoList Array of EcuInfo

The returned list of ECUs.

EcuInfo
AvailableCpu Integer 2

The number of available CPU cores for the ECU.

AvailableMem Integer 111

The amount of available memory for the ECU. Unit: MB

CreateTime Long 1573281040819

The time when the ECU was created, in the timestamp format.

DockerEnv Boolean false

Indicates whether Docker is installed. Valid values:

  • true: Docker is installed.
  • false: Docker is not installed.
EcuId String 0de2ebdb-9490-4fc4-be41***************

The unique ID of the ECU. To query the ID, you can run the dmidecode command on the ECS instance that corresponds to the ECU.

HeartbeatTime Long 1573281040819

The time when the last heartbeat detection was performed.

InstanceId String i-2zej4i2jdf*********

The ID of the ECU.

IpAddr String 192.168.XX.XX

The private IP address of the ECU.

Name String test

The name of the ECU.

Online Boolean true

Indicates whether the ECU is online. If the ECU is online, its corresponding ECS instance is managed in EDAS. Valid values:

  • true: online
  • false: offline
RegionId String cn-beijing

The ID of the region where the ECU is located.

UpdateTime Long 1573281040827

The time when the ECU was last updated, in the timestamp format.

UserId String 1172****6608****

The ID of the Alibaba Cloud account to which the ECU belongs.

VpcId String vpc-2zef6ob8**********

The ID of the VPC where the ECU is located.

ZoneId String cn-beijing-h

The ID of the zone where the ECU is located.

Message String success

The additional information.

RequestId String AF860D6C-ACE3-4429-9D54-3BD15A7F4AE6

The ID of the request.

Examples

Sample requests

POST /pop/v5/resource/scale_out_ecu_list HTTP/1.1
Common request headers

Sample success responses

XML format

<EcuInfoList>
    <EcuInfo>
        <AvailableMem>2048</AvailableMem>
        <InstanceId>i-2zej4i2jdf*********</InstanceId>
        <AvailableCpu>2</AvailableCpu>
        <Online>true</Online>
        <UpdateTime>1573281040827</UpdateTime>
        <ZoneId>cn-beijing-h</ZoneId>
        <VpcId>vpc-2zef6ob8**********</VpcId>
        <IpAddr>192.168. *. **</IpAddr>
        <HeartbeatTime>1573281040819</HeartbeatTime>
        <CreateTime>1573281040819</CreateTime>
        <RegionId>cn-beijing</RegionId>
        <EcuId>0de2ebdb-9490-4fc4-be41***************</EcuId>
        <DockerEnv>false</DockerEnv>
    </EcuInfo>
    <EcuInfo>
        <AvailableMem>2048</AvailableMem>
        <InstanceId>i-2zej4i2j*********</InstanceId>
        <AvailableCpu>2</AvailableCpu>
        <Online>true</Online>
        <UpdateTime>1573281041362</UpdateTime>
        <ZoneId>cn-beijing-h</ZoneId>
        <VpcId>vpc-2ze************</VpcId>
        <IpAddr>192.168.0. **</IpAddr>
        <HeartbeatTime>1573281041355</HeartbeatTime>
        <CreateTime>1573281041355</CreateTime>
        <RegionId>cn-beijing</RegionId>
        <EcuId>6f9cb7fd-bb*****************</EcuId>
        <DockerEnv>false</DockerEnv>
    </EcuInfo>
    <EcuInfo>
        <AvailableMem>2048</AvailableMem>
        <InstanceId>i-2*******e</InstanceId>
        <AvailableCpu>2</AvailableCpu>
        <Online>true</Online>
        <UpdateTime>1573281041109</UpdateTime>
        <ZoneId>cn-beijing-h</ZoneId>
        <VpcId>vpc-2zef6ob********p</VpcId>
        <IpAddr>192.168.0. ***</IpAddr>
        <HeartbeatTime>1573281041101</HeartbeatTime>
        <CreateTime>1573281041101</CreateTime>
        <RegionId>cn-beijing</RegionId>
        <EcuId>70ed3f59-b476-49aa***********</EcuId>
        <DockerEnv>false</DockerEnv>
    </EcuInfo>
    <EcuInfo>
        <AvailableMem>2048</AvailableMem>
        <InstanceId>i-2z********</InstanceId>
        <AvailableCpu>2</AvailableCpu>
        <Online>true</Online>
        <UpdateTime>1573281041150</UpdateTime>
        <ZoneId>cn-beijing-h</ZoneId>
        <VpcId>vpc-2ze************</VpcId>
        <IpAddr>192.168.0. **</IpAddr>
        <HeartbeatTime>1573281041143</HeartbeatTime>
        <CreateTime>1573281041143</CreateTime>
        <RegionId>cn-beijing</RegionId>
        <EcuId>cfe7f474-386******************</EcuId>
        <DockerEnv>false</DockerEnv>
    </EcuInfo>
    <EcuInfo>
        <AvailableMem>2048</AvailableMem>
        <InstanceId>i-2zej4i*********</InstanceId>
        <AvailableCpu>2</AvailableCpu>
        <Online>true</Online>
        <UpdateTime>1573281041300</UpdateTime>
        <ZoneId>cn-beijing-h</ZoneId>
        <VpcId>vpc-2zef**********</VpcId>
        <IpAddr>192.168.0. ***</IpAddr>
        <HeartbeatTime>1573281041292</HeartbeatTime>
        <CreateTime>1573281041292</CreateTime>
        <RegionId>cn-beijing</RegionId>
        <EcuId>f6917537-******************</EcuId>
        <DockerEnv>false</DockerEnv>
    </EcuInfo>
</EcuInfoList>
<Message>success</Message>
<Code>200</Code>

JSON format

{
	"EcuInfoList": {
		"EcuInfo": [
			{
				"AvailableMem": 2048,
				"InstanceId": "i-2zej4i2jdf*********",
				"AvailableCpu": 2,
				"Online": true,
				"UpdateTime": 1573281040827,
				"ZoneId": "cn-beijing-h",
				"VpcId": "vpc-2zef6ob8**********",
				"IpAddr": "192.168. *. **",
				"HeartbeatTime": 1573281040819,
				"CreateTime": 1573281040819,
				"RegionId": "cn-beijing",
				"EcuId": "0de2ebdb-9490-4fc4-be41***************",
				"DockerEnv": false
			},
			{
				"AvailableMem": 2048,
				"InstanceId": "i-2zej4i2j*********",
				"AvailableCpu": 2,
				"Online": true,
				"UpdateTime": 1573281041362,
				"ZoneId": "cn-beijing-h",
				"VpcId": "vpc-2ze************",
				"IpAddr": "192.168.0. **",
				"HeartbeatTime": 1573281041355,
				"CreateTime": 1573281041355,
				"RegionId": "cn-beijing",
				"EcuId": "6f9cb7fd-bb*****************",
				"DockerEnv": false
			},
			{
				"AvailableMem": 2048,
				"InstanceId": "i-2*******e",
				"AvailableCpu": 2,
				"Online": true,
				"UpdateTime": 1573281041109,
				"ZoneId": "cn-beijing-h",
				"VpcId": "vpc-2zef6ob********p",
				"IpAddr": "192.168.0. ***",
				"HeartbeatTime": 1573281041101,
				"CreateTime": 1573281041101,
				"RegionId": "cn-beijing",
				"EcuId": "70ed3f59-b476-49aa***********",
				"DockerEnv": false
			},
			{
				"AvailableMem": 2048,
				"InstanceId": "i-2z********",
				"AvailableCpu": 2,
				"Online": true,
				"UpdateTime": 1573281041150,
				"ZoneId": "cn-beijing-h",
				"VpcId": "vpc-2ze************",
				"IpAddr": "192.168.0. **",
				"HeartbeatTime": 1573281041143,
				"CreateTime": 1573281041143,
				"RegionId": "cn-beijing",
				"EcuId": "cfe7f474-386******************",
				"DockerEnv": false
			},
			{
				"AvailableMem": 2048,
				"InstanceId": "i-2zej4i*********",
				"AvailableCpu": 2,
				"Online": true,
				"UpdateTime": 1573281041300,
				"ZoneId": "cn-beijing-h",
				"VpcId": "vpc-2zef**********",
				"IpAddr": "192.168.0. ***",
				"HeartbeatTime": 1573281041292,
				"CreateTime": 1573281041292,
				"RegionId": "cn-beijing",
				"EcuId": "f6917537-******************",
				"DockerEnv": false
			}
		]
	},
	"Message": "success",
	"Code": 200
}

Error codes

For a list of error codes, visit the API Error Center.