Browse Source

Update Java API doc for cluster health

In 995e4eda08be99f72ef56052b3f78ceef9100885 we changed the cluster health Java API.
We need to also change the documentation.

Backport of #19093 in master branch
David Pilato 9 years ago
parent
commit
b9e8ec1938
1 changed files with 1 additions and 1 deletions
  1. 1 1
      docs/java-api/admin/cluster/health.asciidoc

+ 1 - 1
docs/java-api/admin/cluster/health.asciidoc

@@ -14,7 +14,7 @@ String clusterName = healths.getClusterName();              <2>
 int numberOfDataNodes = healths.getNumberOfDataNodes();     <3>
 int numberOfNodes = healths.getNumberOfNodes();             <4>
 
-for (ClusterIndexHealth health : healths) {                 <5>
+for (ClusterIndexHealth health : healths.getIndices().values()) { <5>
     String index = health.getIndex();                       <6>
     int numberOfShards = health.getNumberOfShards();        <7>
     int numberOfReplicas = health.getNumberOfReplicas();    <8>