Method description
Obtains information about a cluster by a specified cluster ID.
Parameter description
| Parameter | Type | Description |
|---|---|---|
| clusterId | String | Cluster ID |
Response description
If the call succeeds, a GetClusterResponse instance is returned. You can use the getCluster() information of this instance to obtain the Cluster object.
If a failure occurs, a ClientException is thrown.
Sample code
try{GetClusterResponse response = client.getCluster("cls-6vilcufsfd31i010");//SucceededCluster cluster = response.getCluster();String state = cluster.getState();//assertEquals('Active', state); //Cluster stateOptional values include Active and Deleting.}catch(ClientException e){e.printStackTrace();// Failed}