Thanks for your reply.
I am not using the default routing, while indexing i do specify eg: routing=a.
My problem is when i finish indexing for all routing keys i have. Shard 1 remains unallocated.
I need a way such that a,b,c,d,e, (having 5 shards in ES), documents for each routing key goes on separate shard.
I understand that it totally depends on the hash generate for the given keys.
My base problem:
In above example say routing=a and routing=e goes on same shard i.e. 4.
Assume a and e are types of documents, which have few fields in common. When i query documents with routing=a and on common fields, ES also checks all documents in routing=e lowering the performance extensively.
Check this thread
Some issue which i see with shard allocation by routing
If i have 50shards and have 100 routing keys, it may happen that due to the nature of hash generated, some shards will remain unallocated for ever.
Suggestion:
There could be a routing key to shard number mapping in the settings section which will give this control to the user. Such that user will decide which shard the routing key maps to.