789
阿裏雲
技術社區[雲棲]
查詢集群列表__集群_API參考_E-MapReduce-阿裏雲
請求參數
| 字段 |
類型 |
是否必須 |
默認值 |
描述 |
|---|
| StatusList |
Array<String> |
否 |
|
選擇需要的集群狀態進行篩選。使用類似如下的格式的字符串數組:[“CREATING”, “RUNNING”, “IDLE”] |
| RegionId |
String |
|
|
|
| PageNumber |
Integer |
|
|
查詢的頁碼 |
| PageSize |
Integer |
|
|
查詢的頁麵條數 |
返回參數
| 字段 |
類型 |
描述 |
|---|
| Cluster |
Array<ClusterInfoSimple> |
ClusterInfoSimple數組。ClusterInfoSimple結構見下麵的對象。 |
| TotalCount |
Integer |
總條數 |
| PageNumber |
Integer |
當前頁碼 |
| PageSize |
Integer |
當前查詢頁麵條數 |
ClusterInfoSimple
| 字段 |
類型 |
描述 |
|---|
| Id |
String |
集群Id |
| Name |
String |
集群名稱 |
| ChargeType |
String |
集群的付費類型。 PrePaid:包年包月,PostPaid:按量付費 |
| ExpiredTime |
Long |
集群到期的時間,時間戳格式。類似:1459236255438 |
| Type |
String |
集群類型,HADOOP,HBASE |
| CreateTime |
Long |
集群創建的時間,時間戳格式。類似:1459236255438 |
| RunningTime |
Integer |
集群運行的時間,單位:秒 |
| Status |
String |
集群的狀態,參考集群狀態 |
| FailReason |
FailReason |
集群創建失敗的信息 |
| CreateType |
String |
ON-DEMAND:按需創建,指使用執行計劃動態創建出來的集群。MANUAL:手動創建的集群 |
示例
請求示例
https://emr.aliyuncs.com/?Action=ListClusters&PageSize=100&StatusList=%5B%22CREATING%22%2C+%22RUNNING%22%2C+%22IDLE%22%2C+%22RELEASING%22%2C+%22CREATE_FAILED%22%2C+%22RELEASE_FAILED%22%5D&PageNumber=1&RegionId=cn-hangzhou&公共請求參數
返回格式
JSON 格式
{ "code": "200", "data": { "Clusters": { "ClusterInfo": [ { "CreateTime": 1454035046000, "FailReason": { "ErrorCode": "OperationDenied", "ErrorMsg": "The resource is out of usage.", "RequestId": "C0946CDD-25A6-45F5-8F5C-D095F12E8B6B" }, "Id": "500000845", "Name": "ffff", "PayType": "PostPaid", "RunningTime": 0, "Status": "LAUNCHING_FAIL", "Type": "hadoop" }, { "CreateTime": 1454034802000, "FailReason": { "ErrorCode": "OperationDenied", "ErrorMsg": "The resource is out of usage.", "RequestId": "3FCF17ED-9277-40B0-983F-52939B1B8BFF" }, "Id": "500000844", "Name": "testforcerelease", "PayType": "PostPaid", "RunningTime": 0, "Status": "LAUNCHING_FAIL", "Type": "hadoop" }, { "CreateTime": 1453879601000, "FailReason": {}, "Id": "500000760", "Name": "新Hadoop", "PayType": "PostPaid", "RunningTime": 18938, "Status": "TERMINATED", "Type": "hadoop" }, { "CreateTime": 1453877940000, "FailReason": { "ErrorCode": "MissingParameter", "ErrorMsg": "The input parameter "InstanceId" that is mandatory for processing this request is not supplied.", "RequestId": "D1CEBBCD-2FFD-4BBF-A7A0-87FC9378A237" }, "Id": "500000759", "Name": "Cluster_OnDemandWithHourSchedual", "PayType": "PostPaid", "RunningTime": 0, "Status": "LAUNCHING_FAIL", "Type": "hadoop" }, { "CreateTime": 1453877939000, "FailReason": { "ErrorCode": "MissingParameter", "ErrorMsg": "The input parameter "InstanceId" that is mandatory for processing this request is not supplied.", "RequestId": "F06849BF-391A-450D-AC8A-978C7DF798BF" }, "Id": "500000758", "Name": "Cluster_OnDemandWithDaySchedual", "PayType": "PostPaid", "RunningTime": 0, "Status": "LAUNCHING_FAIL", "Type": "hadoop" } ] }, "PageNumber": 1, "PageSize": 100, "RequestId": "C7067848-F4DC-42B4-A596-235F82E43E2E", "TotalCount": 849 }, "requestId": "C7067848-F4DC-42B4-A596-235F82E43E2E", "successResponse": true}
最後更新:2016-11-23 16:03:59