I am using the Java HighLevelRestClient to connect to my ElasticSearch.I was working on a task to get the health status of each nodes.
Tried with :
private string getHighLevelClientInfo(){
try{
ClusterHealthResponse res=restHighLevelClient.cluster().health(new ClusterHealthRequest(),RequestOptions.DEFAULT);
return res.getStatus.name();
}
catch(Exception e){
return "Error";
}
}
While doing so, i was getting all Cluster related information with Status as "Green" and number of nodes=3.
Any help, how to get the node specific information with node status.
Thanks
There is no concept of node health status, it's a cluster health status which is made up of all the indices health status which again in turn made of shard health status.
I guess, you are looking for node stats API, which will print each node stats like, how CPU, memory, various queue size, and several other information.