# Question about routing

**URL:** <https://discuss.elastic.co/t/question-about-routing/12903>\
**Category:** Elasticsearch\
**Created:** [July 23, 2013, 3:03pm UTC](https://discuss.elastic.co/t/question-about-routing/12903 "2013-07-23T15:03:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![nik9000](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nik9000/32/44947_2.png) [@nik9000](https://discuss.elastic.co/u/nik9000)\
**Post date:** [July 23, 2013, 3:03pm UTC](https://discuss.elastic.co/t/question-about-routing/12903/1 "2013-07-23T15:03:29Z")

</div>

It looks like each route key is mapped to a single shard. If I have very  
course route keys - say each one accounts for one tenth of my documents,  
would it be best for me to create some kind of surrogate route key so that  
my documents don't get assigned to just ten shards?

I'm pretty sure I could build the key in such a way so I'd know exactly  
what it is on update but on search I'd need to list a bunch of them. Would  
that be really inefficient on search?

Or is this a horrible idea and I'd be better of creating an index per route  
key?

Nik

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![radu\_gheorghe](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/radu_gheorghe/32/556_2.png) [@radu\_gheorghe](https://discuss.elastic.co/u/radu_gheorghe)\
**Post date:** [July 25, 2013, 10:45am UTC](https://discuss.elastic.co/t/question-about-routing/12903/2 "2013-07-25T10:45:58Z")

</div>

Hello Nik,

My guess is it's not a horrible idea and your searches shouldn't be slow if  
you specify a bunch of routing keys. But I guess it's safer to test before  
proceeding 🙂

If you have a small amount of "natural" routing keys, like 10, I think it's  
easier to just make 10 indices and use  
aliases[http://www.elasticsearch.org/guide/reference/api/admin-indices-aliases/](http://www.elasticsearch.org/guide/reference/api/admin-indices-aliases/)when  
you want to search through multiple routing keys. It just seems easier  
for me, and as long as you don't have too many indices (eg: 200) in too  
little nodes (eg: 2 small ones)

Best regards,  
Radu

On Tue, Jul 23, 2013 at 6:03 PM, Nikolas Everett [nik9000@gmail.com](mailto:nik9000@gmail.com) wrote:

> It looks like each route key is mapped to a single shard. If I have very  
> course route keys - say each one accounts for one tenth of my documents,  
> would it be best for me to create some kind of surrogate route key so that  
> my documents don't get assigned to just ten shards?
> 
> I'm pretty sure I could build the key in such a way so I'd know exactly  
> what it is on update but on search I'd need to list a bunch of them. Would  
> that be really inefficient on search?
> 
> Or is this a horrible idea and I'd be better of creating an index per  
> route key?
> 
> Nik
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
[http://sematext.com/](http://sematext.com/) -- Elasticsearch -- Solr -- Lucene

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 2:24am UTC](https://discuss.elastic.co/t/question-about-routing/12903/3 "2017-07-06T02:24:36Z")

</div>


