Mengkueri daftar node yang memenuhi kondisi tertentu dalam sebuah kluster.
Coba sekarang
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
cs:DescribeClusterNodes |
get |
*Cluster
|
None | None |
Sintaks permintaan
GET /clusters/{ClusterId}/nodes HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| ClusterId |
string |
Yes |
ID kluster. |
c82e6987e2961451182edacd74faf**** |
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| instanceIds |
string |
No |
Daftar ID instans node. Pisahkan beberapa ID dengan koma (,). |
"i-bp11xjhwkj8k966u****,i-bp1dmhc2bu5igkyq****" |
| nodepool_id |
string |
No |
ID kelompok node. |
npe25633140a7d4fbea56cd0479c****** |
| state |
string |
No |
Status node kluster. Memfilter node berdasarkan status berjalan. Nilai valid:
Nilai default: |
running |
| pageSize |
string |
No |
Jumlah maksimum catatan yang dapat ditampilkan per halaman. Nilai valid: [1,100]. Nilai default: 10. |
10 |
| pageNumber |
string |
No |
Nomor halaman dari kueri saat ini. Nilai default: 1. |
1 |
| nodeNames |
string |
No |
cn-hangzhou.192.168.0.1 |
|
| nodeIps |
string |
No |
192.168.0.1 |
|
| nodeLabels |
string |
No |
nodeLabels=app=nginx,env=prod |
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
Badan respons. |
||
| nodes |
array<object> |
Daftar detail node. |
|
|
object |
Detail node. |
||
| creation_time |
string |
Pengatur waktu saat node dibuat. |
2025-04-16T07:28:00Z |
| error_message |
string |
Paket error yang dihasilkan saat node dibuat. |
error*** |
| expired_time |
string |
Pengatur waktu saat node kedaluwarsa. |
2099-12-31T15:59:00Z |
| host_name |
string |
Hostname node. |
iZ2vcckdmxp7u0urj2k**** |
| image_id |
string |
ID image sistem yang digunakan oleh node. |
aliyun_3_x64_20G_alibase_20241218.vhd |
| instance_charge_type |
string |
Metode penagihan node. Nilai valid:
|
PostPaid |
| instance_id |
string |
ID instans node. |
i-2vcckdmxp7u0urj2**** |
| instance_name |
string |
Nama node dalam kluster. |
worker-k8s-for-cs-c5cdf7e3938bc4f8eb0e44b21a80f**** |
| instance_role |
string |
Tipe peran node. Nilai valid:
|
Worker |
| instance_status |
string |
Status ECS node. Nilai valid:
|
Running |
| instance_type |
string |
Spesifikasi node. |
ecs.c5.xlarge |
| instance_type_family |
string |
Nama keluarga instans ECS tempat node berada. |
ecs.c5 |
| ip_address |
array |
Alamat IP node. |
|
|
string |
Alamat IP. |
192.168.xx.xx |
|
| is_aliyun_node |
boolean |
Apakah node merupakan instans Alibaba Cloud. Nilai valid:
|
true |
| node_name |
string |
Nama node, yang merupakan pengenal node dalam kluster. |
cn-chengdu.192.168xx.xx |
| node_status |
string |
Apakah node sudah siap. Nilai valid:
|
Ready |
| nodepool_id |
string |
ID kelompok node. |
np0794239424a84eb7a95327369d56**** |
| source |
string |
Metode yang digunakan untuk menginisialisasi node, seperti pembuatan manual atau pembuatan ROS. |
ess |
| state |
string |
Status berjalan node. Nilai valid:
|
running |
| spot_strategy |
string |
Tipe instans spot. Nilai valid:
|
NoSpot |
| page |
object |
Informasi paginasi. |
|
| page_number |
integer |
Nomor halaman saat ini. |
1 |
| page_size |
integer |
Jumlah maksimum catatan yang dapat ditampilkan per halaman. |
10 |
| total_count |
integer |
Jumlah total hasil. |
5 |
Contoh
Respons sukses
JSONformat
{
"nodes": [
{
"creation_time": "2025-04-16T07:28:00Z",
"error_message": "error***",
"expired_time": "2099-12-31T15:59:00Z",
"host_name": "iZ2vcckdmxp7u0urj2k****",
"image_id": "aliyun_3_x64_20G_alibase_20241218.vhd",
"instance_charge_type": "PostPaid",
"instance_id": "i-2vcckdmxp7u0urj2****",
"instance_name": "worker-k8s-for-cs-c5cdf7e3938bc4f8eb0e44b21a80f****",
"instance_role": "Worker",
"instance_status": "Running",
"instance_type": "ecs.c5.xlarge",
"instance_type_family": "ecs.c5",
"ip_address": [
"192.168.xx.xx"
],
"is_aliyun_node": true,
"node_name": "cn-chengdu.192.168xx.xx",
"node_status": "Ready",
"nodepool_id": "np0794239424a84eb7a95327369d56****",
"source": "ess",
"state": "running",
"spot_strategy": "NoSpot"
}
],
"page": {
"page_number": 1,
"page_size": 10,
"total_count": 5
}
}
Kode kesalahan
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.