You can call the ListFlowCluster operation to query the clusters that are available for a project.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. You can use OpenAPI Explorer to search for API operations, call API operations, and dynamically generate SDK sample code.

Request parameters

Parameter Type Required Example Description
Action String Yes ListFlowCluster

The operation that you want to perform. This parameter is required for API requests that you create by piecing together HTTP or HTTPS URLs. Set the value to ListFlowCluster.

ProjectId String Yes FP-5D55DA9DEDF2****

The ID of the project. You can call ListFlowProject View the ID of the project.

RegionId String Yes cn-hangzhou

The region ID of the instance. You can call DescribeRegions To view the latest list of Alibaba Cloud regions.

PageNumber Integer No 1

The number of the page to return. Pages start from page 1.

PageSize Integer No 10

The number of entries returned per page.

ResourceGroupId String No rg-acfmv6jutt6****

The ID of the resource group. You can call ListResourceGroups View the resource group ID.

Response parameters

Parameter Type Example Description
Clusters Array of ClusterInfo

The list of clusters available in a project.

ClusterInfo
ChargeType String PostPaid

The billing method of the instance. Default value: Postpaid. Valid values:

  • PostPaid: pay-as-you-go clusters
  • PrePaid: subscription cluster
CreateResource String ECM_EMR

The label of the cluster.

CreateTime Long 1542953603000

The creation time of the cluster.

ExpiredTime Long 1542953605000

The expiration time of the cluster.

FailReason Struct

The cause of the cluster failure.

ErrorCode String 400

The error code of the failure.

ErrorMsg String failed

The error message of the failure.

RequestId String 0d18b019-00ab-455f-b60c-2891bf02f538

The ID of the request.

HasUncompletedOrder Boolean false

Uncompleted orders:

  • true: there are outstanding orders.
  • false: there are no unfinished orders.
Id String C-2E6ABBD39BD0****

The ID of the cluster.

K8sClusterId String None

A reserved parameter.

Name String my_cluster

The name of the cluster.

OrderList String 1,2

The list of orders.

OrderTaskInfo Struct

The information of the order.

CurrentCount Integer 2

The number of completed orders.

OrderIdList String 1,2

The list of order IDs.

TargetCount Integer 2

The target number of orders to be completed.

Period Integer 1

The length of the subscription. Valid values: 1, 2, 3, 4, 5, 6, 7, 8, 9, 12, 24, and 36. Unit: months. Set this parameter when ChargeType is set to PrePaid.

RunningTime Integer 200

The execution time of the cluster. Unit: seconds.

Status String IDLE

The status of the cluster. Valid values:

  • CREATING: the cluster is being created.
  • CREATE_FAILED: the cluster fails to be created.
  • RUNNING
  • IDLE: the cluster is IDLE.
  • RELEASING: the cluster is being released.
  • RELEASE_FAILED: the cluster fails to be released.
  • RELEASED: the cluster has been RELEASED.
  • WAIT_FOR_PAY: to be paid
  • ABNORMAL: the cluster status is ABNORMAL.
Type String HADOOP

Cluster Type:

  • HADOOP
  • KAFKA
  • GATEWAY
  • DRUID
  • ZOOKEEPER
  • DATA_SCIENCE
PageNumber Integer 1

The number of the page to return. Pages start from page 1.

PageSize Integer 10

The number of automatic snapshot tasks returned per page.

RequestId String 0d18b019-00ab-455f-b60c-2891bf02f538

The ID of the request.

TotalCount Integer 2

The total number of returned entries.

Examples

Sample requests

http(s)://[Endpoint]/?Action=ListFlowCluster
&ProjectId=FP-5D55DA9DEDF2****
&RegionId=cn-hangzhou
&<common request parameters>

Sample success responses

XML format

<TotalCount>2</TotalCount>
<PageSize>10</PageSize>
<PageNumber>1</PageNumber>
<Clusters>
    <ClusterInfo>
        <Status>IDLE</Status>
        <Type>HADOOP</Type>
        <CreateResource>ECM_EMR</CreateResource>
        <ChargeType>PostPaid</ChargeType>
        <OrderTaskInfo/>
        <CreateTime>1542953603000</CreateTime>
        <FailReason/>
        <Id>C-4042079DFF01****</Id>
        <HasUncompletedOrder>false</HasUncompletedOrder>
        <RunningTime>1322</RunningTime>
        <Name>zx-presto-1</Name>
    </ClusterInfo>
    <ClusterInfo>
        <Status>IDLE</Status>
        <Type>HADOOP</Type>
        <CreateResource>ECM_EMR</CreateResource>
        <ChargeType>PostPaid</ChargeType>
        <OrderTaskInfo/>
        <CreateTime>1542950611000</CreateTime>
        <FailReason/>
        <Id>C-3D0B53253595****</Id>
        <HasUncompletedOrder>false</HasUncompletedOrder>
        <RunningTime>4314</RunningTime>
        <Name>zx-presto-213</Name>
    </ClusterInfo>
</Clusters>

JSON Syntax

{
    "TotalCount": 2,
    "PageSize": 10,
    "PageNumber": 1,
    "Clusters": {
        "ClusterInfo": [
            {
                "Status": "IDLE",
                "Type": "HADOOP",
                "CreateResource": "ECM_EMR",
                "ChargeType": "PostPaid",
                "OrderTaskInfo": {},
                "CreateTime": 1542953603000,
                "FailReason": {},
                "Id": "C-4042079DFF01****",
                "HasUncompletedOrder": false,
                "RunningTime": 1322,
                "Name": "zx-presto-1"
            },
            {
                "Status": "IDLE",
                "Type": "HADOOP",
                "CreateResource": "ECM_EMR",
                "ChargeType": "PostPaid",
                "OrderTaskInfo": {},
                "CreateTime": 1542950611000,
                "FailReason": {},
                "Id": "C-3D0B53253595****",
                "HasUncompletedOrder": false,
                "RunningTime": 4314,
                "Name": "zx-presto-213"
            }
        ]
    }
}

Error code

The port number of a client that accesses a Error CenterFor more information, see error codes.