# Search Response Time for "match all" query

**URL:** <https://discuss.elastic.co/t/search-response-time-for-match-all-query/13779>\
**Category:** Elasticsearch\
**Created:** [September 26, 2013, 9:53pm UTC](https://discuss.elastic.co/t/search-response-time-for-match-all-query/13779 "2013-09-26T21:53:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Phani](https://avatars.discourse-cdn.com/v4/letter/p/f1d935/32.png) [@Phani](https://discuss.elastic.co/u/Phani)\
**Post date:** [September 26, 2013, 9:53pm UTC](https://discuss.elastic.co/t/search-response-time-for-match-all-query/13779/1 "2013-09-26T21:53:49Z")

</div>

Hi all,

I'm experimenting with ES (version 0.90.5) for indexing/search  
performance. Below is my cluster setup :

1. Master on separate machine (node.master: true, node.data : false)
2. 4 data nodes on separate machines (node.master: false, node.data:  
true)
3. index.num\_of\_shards = 4 & index.num\_replicas = 1

Those are the only settings I've changed in the elasticsearch.yml file of  
respective nodes.

I'm comparing the performance with Solr (essentially SolrCloud) 4.4  
version. I indexed 4 million documents where each document has 10 english  
sentences (each sentence is about 10 words).

So each primary shard has approximately 1 million docs which is nice as  
I've 4 million docs and 4 shards.

I'm running the following queries (I'm using a cluster and no other  
processes are running on it apart from ES).

1. "\*" query - to get all docs (i.e. 4 Million hits)
2. "\*" query with size set to 100 - to get only top 100 hits
3. a term query with size again set to 4 Million to retrieve all rows
4. same term query with size set to 100 - to get only top 100 hits

It is encouraging to see the response times of queries 2,3 & 4 when  
compared to Solr (SolrCloud) - ES is 2-3 times faster for 2 & 4 and  
consistently faster for 3.

But for 1 - it takes hell lot of time compared to SolrCloud. ES took 279  
secs where as SolrCloud took 55 secs.

Why is it the "match\_all" query is ES is taking so much more time compared  
to Solr ? Is the "match\_all" query a bottleneck for ES / known limitation  
for ES.

Thanks,  
Phani.

--  
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:14am UTC](https://discuss.elastic.co/t/search-response-time-for-match-all-query/13779/2 "2017-07-06T02:14:29Z")

</div>


