wait for status should wait for at least that provided status, for example, waiting for status yellow should return if the status is green

This commit is contained in:
kimchy 2010-03-04 15:09:11 +02:00
parent 5d947ad680
commit c560f1f9f1
1 changed files with 1 additions and 1 deletions

View File

@ -82,7 +82,7 @@ public class TransportClusterHealthAction extends TransportMasterNodeOperationAc
while (true) {
int waitForCounter = 0;
ClusterHealthResponse response = clusterHealth(request);
if (request.waitForStatus() != null && response.status() == request.waitForStatus()) {
if (request.waitForStatus() != null && response.status().value() <= request.waitForStatus().value()) {
waitForCounter++;
}
if (request.waitForRelocatingShards() != -1 && response.relocatingShards() <= request.waitForRelocatingShards()) {