All Products
Search
Document Center

Enterprise Distributed Application Service:GetCluster

Last Updated:Mar 01, 2024

Queries a specific cluster.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
edas:ReadClusterRead
  • Cluster
    acs:edas:{#regionId}:{#accountId}:namespace/{#NameSpaceId}/cluster/{#ClusterId}
    none
none

Request syntax

GET /pop/v5/resource/cluster

Request parameters

ParameterTypeRequiredDescriptionExample
ClusterIdstringYes

The ID of the cluster in Enterprise Distributed Application Service (EDAS). You can call the ListCluster operation to query the cluster ID. For more information, see ListCluster .

5439271a-015b-433d-****-d76db49****

Response parameters

ParameterTypeDescriptionExample
object
Codeinteger

The HTTP status code that is returned.

200
Messagestring

The detailed information that is returned.

success
RequestIdstring

The ID of the request.

d76db491
Clusterobject

The information about the cluster.

VpcIdstring

The ID of the virtual private cloud (VPC).

vpc-xxxxz1mlwpb****
OversoldFactorinteger

The overcommit ratio supported by a Docker cluster. Valid values:

  • 1: 1:1, which means that resources are not overcommitted.
  • 2: 1:2, which means that resources are overcommitted by 1:2.
  • 4: 1:4, which means that resources are overcommitted by 1:4.
  • 8: 1:8, which means that resources are overcommitted by 1:8.
2
UpdateTimelong

The time when the cluster was last modified. This value is a UNIX timestamp representing the number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC.

1570708232145
MemUsedinteger

The size of used memory. Unit: MB.

1024
IaasProviderstring

The provider of Infrastructure as a Service (IaaS) resources used in the cluster.

ALIYUN
CreateTimelong

The time when the cluster was created. This value is a UNIX timestamp representing the number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC.

1570708232145
CpuUsedinteger

The number of used CPU cores.

2
Meminteger

The total size of memory. Unit: MB.

2048
RegionIdstring

The ID of the region where the cluster resides.

cn-hangzhou
Cpuinteger

The total number of CPU cores.

4
CsClusterIdstring

The ID of the Container Service for Kubernetes (ACK) cluster.

c2ce62869f4d4466b920312315f05****
NetworkModeinteger

The network type of the cluster. Valid values:

  • 1: classic network
  • 2: virtual private cloud (VPC)
2
Descriptionstring

The description of the cluster.

Test
ClusterTypeinteger

The type of the cluster. Valid values:

  • 0: regular Docker cluster
  • 1: Swarm cluster
  • 2: Elastic Compute Service (ECS) cluster
  • 3: self-managed Kubernetes cluster in EDAS
  • 4: cluster in which Pandora automatically registers applications
  • 5: ACK cluster
2
ClusterNamestring

The name of the cluster.

ClusterTest
NodeNuminteger

The number of ECS instances.

4
ClusterImportStatusinteger

The import status of the cluster. Valid values:

  • 1: The cluster is imported.
  • 2: The cluster fails to be imported.
  • 3: The cluster is being imported.
  • 4: The cluster is deleted.
  • 0: The cluster is not imported.
0
ClusterIdstring

The ID of the cluster.

5439271a-015b-433d-befb-d76d****
SubClusterTypestring

The subtype of the Kubernetes cluster. Valid values: ManagedKubernetes, Ask, and ExternalKubernetes. ManagedKubernetes refers to the ACK cluster. Ask refers to the Serverless Kubernetes (ASK) cluster. ExternalKubernetes refers to the external cluster.

ManagedKubernetes

Examples

Sample success responses

JSONformat

{
  "Code": 200,
  "Message": "success",
  "RequestId": "d76db491",
  "Cluster": {
    "VpcId": "vpc-xxxxz1mlwpb****",
    "OversoldFactor": 2,
    "UpdateTime": 1570708232145,
    "MemUsed": 1024,
    "IaasProvider": "ALIYUN",
    "CreateTime": 1570708232145,
    "CpuUsed": 2,
    "Mem": 2048,
    "RegionId": "cn-hangzhou",
    "Cpu": 4,
    "CsClusterId": "c2ce62869f4d4466b920312315f05****",
    "NetworkMode": 2,
    "Description": "Test\n",
    "ClusterType": 2,
    "ClusterName": "ClusterTest",
    "NodeNum": 4,
    "ClusterImportStatus": 0,
    "ClusterId": "5439271a-015b-433d-befb-d76d****",
    "SubClusterType": "ManagedKubernetes"
  }
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2022-06-16The response structure of the API has changedsee changesets
Change itemChange content
Output ParametersThe response structure of the API has changed.