public ClusterMetrics getClusterMetrics() {
   ClusterMetrics cluster = null;
   try {
     cluster = client.getClusterMetrics();
   } catch (Exception e) {
     System.out.println(e);
   }
   return cluster;
 }
示例#2
0
 /**
  * Get current cluster status.
  *
  * @return object of {@link ClusterMetrics}
  * @throws IOException
  * @throws InterruptedException
  */
 public ClusterMetrics getClusterStatus() throws IOException, InterruptedException {
   return client.getClusterMetrics();
 }