Help Center> Cloud Stream Service> API Reference> APIs> APIs Related to Cluster Management> Querying Information About Exclusive Clusters

Querying Information About Exclusive Clusters

Function

This API is used to query information about exclusive clusters created by users.

URI

  • URI format

    GET /v1.0/{project_id}/reserved_cluster/{cluster_id}

  • Parameter description
    Table 1 URI parameter description

    Parameter

    Mandatory

    Description

    project_id

    Yes

    Project ID. For details about how to obtain the project ID, see Obtaining a Project ID.

    cluster_id

    Yes

    ID of an exclusive cluster.

Request

None

Response

  • Example response
    {
      "message_id": "CS.21010",
      "message": "Querying the cluster information succeeds.",
      "payload": {
        "cluster_id": 10,
        "name": "mycluster2",
        "desc": "Cluster description",
        "status_code": 5,
        "status_name": "cluster_running",
        "status_desc": "cluster_running",
        "spu_used": 0,
        "maximum_spu_quota": 100,
       
        "region_id": "cn-north-1",
        
        
        
        "error_reason": "",
        "created_at": 1550081520879,
        "vpc_cidr": "172.16.0.0/23",
        "subnet_cidr": "172.16.0.0/23",
        "subnet_gateway": "172.16.0.1",
        "manager_node_spu": "2",
        "sys_enterprise_project_id": "0"
      },
      "current_time": 1550199088218
    }
  • Parameter description
    Table 2 Response parameters

    Parameter

    Mandatory

    Type

    Description

    message_id

    No

    String

    Message type ID.

    message

    No

    String

    Message content.

    current_time

    No

    Int

    Current time, expressed by milliseconds.

    payload

    No

    Array of objects

    Information about the exclusive cluster.

    Table 3 payload parameter description

    Parameter

    Mandatory

    Type

    Description

    cluster_id

    No

    String

    Cluster ID.

    name

    No

    String

    Cluster name.

    desc

    No

    String

    Cluster description.

    status_code

    No

    Integer

    Status code for a cluster. For details, see Table 4.

    status_name

    No

    String

    Status name of a cluster.

    Available cluster statuses are as follows:

    • Creating
    • ECS creation failed
    • Ready to start
    • Starting
    • Running
    • Stopping
    • Stop failed
    • Stopped
    • Restarting
    • Deleting
    • Deleted
    • Deletion failed
    • Arrears, Stopping
    • Arrears, Stop failed
    • Arrears stopped
    • Restoring (recharged cluster)
    • Thaw recovery failed

    status_desc

    No

    String

    Status description of a cluster.

    region_id

    No

    String

    Region where a cluster is currently located.

    spu_used

    No

    String

    SPU quota used by a cluster.

    maximum_spu_quota

    No

    String

    Maximum SPU quota of a cluster.

    error_reason

    No

    String

    Cause of the error that results in cluster status exceptions.

    created_at

    No

    String

    Time when a cluster is created.

    Table 4 Cluster Status Code

    Status Code

    Status Description

    1

    A cluster is being created.

    2

    A cluster fails to be created.

    3

    A cluster is created successfully.

    4

    A cluster is starting.

    5

    A cluster is running.

    6

    A cluster is abnormal but still running.

    7

    A cluster is abnormal and has stopped.

    8

    A cluster is in the idle state.

    9

    A cluster is being stopped.

    10

    A cluster fails to be stopped.

    11

    A cluster has stopped.

    12

    A cluster is stopped successfully.

    13

    A cluster stops because the tenant account is in arrears.

    14

    A cluster that stops due to arrears is restored after the account is recharged.

    15

    A cluster is deleted because the tenant account is in arrears and not recharged within the validity period.

    16

    A cluster is being deleted.

    17

    A cluster fails to be deleted.

    18

    A cluster is being upgraded.

    19

    A cluster fails to be upgraded.

    20

    Capacity expansion of a cluster is in progress.

    25

    A cluster is being stopped because the tenant account is in arrears.

    26

    A cluster fails to stop because the tenant account is in arrears.

    27

    A cluster that stops due to arrears fails to be restored after the account is recharged.

    28

    The tenant manually restarts the cluster.

    29

    A cluster is deleted because the tenant has stopped the service.

Status Code

Table 5 describes the status code.

Table 5 Status code

Status Code

Description

200

Querying the information about exclusive clusters succeeds.

400

The input parameters are invalid.

Error Code

For details, see Error Codes.