You can call DescribeClusterNodePools to query node pools in a cluster.
Debugging
Request parameter types
This operation uses only common request parameters. For more information, see Common parameters.
Request syntax
get /clusters/{ClusterId}/nodepools http|https
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
ClusterId | String | Yes | cc0f87de0b8fb403f86e10e204f83**** |
The ID of the cluster. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
nodepools | Array of nodepools |
A list of node pools. |
|
auto_scaling | Object |
The configuration of auto scaling. |
|
eip_bandwidth | Long | "5" |
The peak bandwidth of the elastic IP address (EIP). |
eip_internet_charge_type | String | "***" |
The billing method of the EIP. |
enable | Boolean | "true" |
Indicates whether auto scaling is enabled for the node pool. |
health_check_type | String | "***" |
The health check method of the nodes for auto scaling. |
max_instances | Long | "10" |
The maximum number of the Elastic Compute Service (ECS) instances. |
min_instances | Long | "2" |
The minimum number of ECS instances. |
type | String | "cpu" |
The type of auto scaling. |
kubernetes_config | Object |
The configuration of the cluster. |
|
cms_enabled | Boolean | "true" |
Indicates whether Cloud Monitor is enabled. |
cpu_policy | String | "none" |
The CPU management policy. Valid values: static and none. |
labels | Array of labels |
The tags of the ECS instance. |
|
key | String | "k-aa" |
The key of the tag. |
value | String | "v-aa" |
The value of the tag. |
node_name_mode | String | "nodeip" |
The naming rule of the node. |
overwrite_hostname | Boolean | "false" |
Indicates whether the host name is overwritten. |
runtime | String | "docker" |
The name of the container runtime. |
runtime_version | String | "19.03.5" |
The version of the container runtime. |
taints | Array of taints |
The taints of the node. |
|
effect | String | "NoSca" |
The scheduling policy. |
key | String | "k-bb" |
The key of the taint. |
value | String | "v-bb" |
The value of the taint. |
user_data | String | "***" |
The user data of the node. |
nodepool_info | Object |
The information about the node pool. |
|
created | String | "2020-09-27T19:14:09.156823496+08:00" |
The time when the node pool was created. |
is_default | Boolean | "true" |
Indicates whether the node pool is the default node pool. |
name | String | "default-nodepool" |
The name of the node pool. |
nodepool_id | String | "np615c0e0966124216a0412e10afe0****" |
The ID of the node pool. |
region_id | String | "cn-beijing" |
The ID of the region. |
resource_group_id | String | "***" |
The ID of the resource group. |
type | String | "ess" |
The type of the node. |
updated | String | "2020-09-27T20:37:46+08:00" |
The time when the cluster was updated. |
scaling_group | Object |
The configuration of the scaling group. |
|
auto_renew | Boolean | "false" |
Indicates whether auto renewal is enabled for the nodes. Valid values:
|
auto_renew_period | Long | "0" |
The auto renewal period for nodes. Valid values: 1, 2, 3, 6, and 12. |
data_disks | Array of data_disks |
The configuration of data disks. |
|
category | String | "cloud_efficiency" |
The type of data disks. Valid values:
|
encrypted | String | "false" |
Indicates whether data disks are encrypted. |
size | Long | "40" |
The size of a data disk. |
image_id | String | "aliyun_2_1903_x64_20G_alibase_20200529.vhd" |
The ID of the custom image. |
instance_charge_type | String | "PostPaid" |
The billing method of the nodes. Valid values:
Default value: PostPaid. |
instance_types | Array of String | "ecs.n4.large" |
The ECS instance types of nodes. |
multi_az_policy | String | "BALANCE" |
The scaling policy for the multi-zone scaling group. |
period | Long | "0" |
The subscription duration of nodes. Valid values: 1, 2, 3, 6, and 12. |
period_unit | String | "*" |
The unit of the subscription duration. A value of Month indicates that the subscription duration is measured in months. |
platform | String | "AliyunLinux" |
The release version of the operating system. Valid values: CentOS AliyunLinux Windows WindowsCore |
ram_policy | String | "KubernetesWorkerRole-021dc54f-929b-437a-8ae0-34c24d3e****" |
The name of the RAM role. |
rds_instances | Array of String |
The RDS instances. |
|
scaling_group_id | String | "***" |
The ID of the scaling group. |
scaling_policy | String | "release" |
The policy for auto scaling. |
security_group_id | String | "sg-2ze1iuk12m2sb4c4****" |
The ID of the security group. |
system_disk_category | String | "cloud_efficiency" |
The type of the system disk. Valid values:
|
system_disk_size | Long | "120" |
The size of the system disk. |
tags | Array of tags |
The tags of the nodes. |
|
key | String | "k-cc" |
The key of the tag. |
value | String | "v-cc" |
The value of the tag. |
vswitch_ids | Array of String |
The IDs of VSwitches. |
|
worker_hpc_cluster_id | String | "***" |
The ID of the high-performance computing cluster. |
status | Object |
The status of the node pool. |
|
failed_nodes | Long | "0" |
The number of failed nodes. |
healthy_nodes | Long | "3" |
The number of healthy nodes. |
initial_nodes | Long | "0" |
The number of nodes that are initializing. |
offline_nodes | Long | "0" |
The number of offline nodes. |
removing_nodes | Long | "0" |
The number of nodes that are being removed. |
serving_nodes | Long | "3" |
The number of running nodes. |
state | String | "active" |
The status of the node pool. |
total_nodes | Long | "3" |
The total number of nodes. |
tee_config | Object |
The configuration of confidential computing. |
|
tee_enable | Boolean | "false" |
Indicates whether confidential computing is enabled for the node pool. |
Examples
Sample requests
POST /clusters/{ClusterId}/nodepools HTTP/1.1
{
"ClusterId":"c61da77e8bfbc4c4c999af2b51b65****"
}
Sample success responses
XML
format
<nodepools>
<tee_config>
<tee_enable>false</tee_enable>
</tee_config>
<scaling_group>
<instance_types>ecs.n4.large</instance_types>
<scaling_group_id>***</scaling_group_id>
<auto_renew_period>0</auto_renew_period>
<period>0</period>
<period_unit>*</period_unit>
<security_group_id>sg-2ze1iuk12m2sb4c4****</security_group_id>
<multi_az_policy>BALANCE</multi_az_policy>
<system_disk_size>120</system_disk_size>
<platform>AliyunLinux</platform>
<tags>
<value>v-cc</value>
<key>k-cc</key>
</tags>
<worker_hpc_cluster_id>***</worker_hpc_cluster_id>
<data_disks>
<encrypted>false</encrypted>
<size>40</size>
<category>cloud_efficiency</category>
</data_disks>
<ram_policy>KubernetesWorkerRole-021dc54f-929b-437a-8ae0-34c24d3e****</ram_policy>
<auto_renew>false</auto_renew>
<instance_charge_type>PostPaid</instance_charge_type>
<system_disk_category>cloud_efficiency</system_disk_category>
<rds_instances>rds-xxx</rds_instances>
<image_id>aliyun_2_1903_x64_20G_alibase_20200529.vhd</image_id>
<scaling_policy>release</scaling_policy>
<vswitch_ids>vsw-2ze3ds0mdip0hdz8i****</vswitch_ids>
</scaling_group>
<kubernetes_config>
<runtime_version>19.03.5</runtime_version>
<cpu_policy>none</cpu_policy>
<cms_enabled>true</cms_enabled>
<overwrite_hostname>false</overwrite_hostname>
<runtime>docker</runtime>
<taints>
<effect>NoSca</effect>
<value>v-bb</value>
<key>k-bb</key>
</taints>
<user_data>***</user_data>
<node_name_mode>nodeip</node_name_mode>
<labels>
<value>v-aa</value>
<key>k-aa</key>
</labels>
</kubernetes_config>
<auto_scaling>
<health_check_type>***</health_check_type>
<eip_internet_charge_type>***</eip_internet_charge_type>
<enable>true</enable>
<max_instances>10</max_instances>
<min_instances>2</min_instances>
<eip_bandwidth>5</eip_bandwidth>
<type>cpu</type>
</auto_scaling>
<nodepool_info>
<resource_group_id>***</resource_group_id>
<created>2020-09-27T19:14:09.156823496+08:00</created>
<name>default-nodepool</name>
<region_id>cn-beijing</region_id>
<is_default>true</is_default>
<type>ess</type>
<nodepool_id>np615c0e0966124216a0412e10afe0****</nodepool_id>
<updated>2020-09-27T20:37:46+08:00</updated>
</nodepool_info>
<status>
<serving_nodes>3</serving_nodes>
<total_nodes>3</total_nodes>
<state>active</state>
<initial_nodes>0</initial_nodes>
<offline_nodes>0</offline_nodes>
<removing_nodes>0</removing_nodes>
<failed_nodes>0</failed_nodes>
<healthy_nodes>3</healthy_nodes>
</status>
</nodepools>
JSON
format
{
"nodepools": [
{
"tee_config": {
"tee_enable": "false"
},
"scaling_group": {
"instance_types": "ecs.n4.large",
"scaling_group_id": "***",
"auto_renew_period": "0",
"period": "0",
"period_unit": "*",
"security_group_id": "sg-2ze1iuk12m2sb4c4****",
"multi_az_policy": "BALANCE",
"system_disk_size": "120",
"platform": "AliyunLinux",
"tags": [
{
"value": "v-cc",
"key": "k-cc"
}
],
"worker_hpc_cluster_id": "***",
"data_disks": [
{
"encrypted": "false",
"size": "40",
"category": "cloud_efficiency"
}
],
"ram_policy": "KubernetesWorkerRole-021dc54f-929b-437a-8ae0-34c24d3e****",
"auto_renew": "false",
"instance_charge_type": "PostPaid",
"system_disk_category": "cloud_efficiency",
"rds_instances": "rds-xxx",
"image_id": "aliyun_2_1903_x64_20G_alibase_20200529.vhd",
"scaling_policy": "release",
"vswitch_ids": "vsw-2ze3ds0mdip0hdz8i****"
},
"kubernetes_config": {
"runtime_version": "19.03.5",
"cpu_policy": "none",
"cms_enabled": "true",
"overwrite_hostname": "false",
"runtime": "docker",
"taints": [
{
"effect": "NoSca",
"value": "v-bb",
"key": "k-bb"
}
],
"user_data": "***",
"node_name_mode": "nodeip",
"labels": [
{
"value": "v-aa",
"key": "k-aa"
}
]
},
"auto_scaling": {
"health_check_type": "***",
"eip_internet_charge_type": "***",
"enable": "true",
"max_instances": "10",
"min_instances": "2",
"eip_bandwidth": "5",
"type": "cpu"
},
"nodepool_info": {
"resource_group_id": "***",
"created": "2020-09-27T19:14:09.156823496+08:00",
"name": "default-nodepool",
"region_id": "cn-beijing",
"is_default": "true",
"type": "ess",
"nodepool_id": "np615c0e0966124216a0412e10afe0****",
"updated": "2020-09-27T20:37:46+08:00"
},
"status": {
"serving_nodes": "3",
"total_nodes": "3",
"state": "active",
"initial_nodes": "0",
"offline_nodes": "0",
"removing_nodes": "0",
"failed_nodes": "0",
"healthy_nodes": "3"
}
}
]
}
Error codes
For a list of error codes, visit the API Error Center.