Fix search shards count method when targeting concrete and routing-aliased indices

This commit is contained in:
Benjamin Devèze 2013-06-30 19:12:53 +02:00 committed by Luca Cavanna
parent 28e867b5c1
commit 8e137b1450
1 changed files with 4 additions and 0 deletions

View File

@ -130,6 +130,10 @@ public class PlainOperationRouting extends AbstractComponent implements Operatio
// we might get duplicates, but that's ok, its an estimated count? (we just want to know if its 1 or not)
set.add(indexShard.shardId());
}
} else {
for (IndexShardRoutingTable indexShard : indexRouting) {
set.add(indexShard.shardId());
}
}
}
return set.size();