# What would be the effect of using an arbitrary large count

**URL:** <https://discuss.elastic.co/t/what-would-be-the-effect-of-using-an-arbitrary-large-count/21074>\
**Category:** Elasticsearch\
**Created:** [December 4, 2014, 4:40am UTC](https://discuss.elastic.co/t/what-would-be-the-effect-of-using-an-arbitrary-large-count/21074 "2014-12-04T04:40:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ron\_Sher](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ron_sher/32/4472_2.png) [@Ron\_Sher](https://discuss.elastic.co/u/Ron_Sher)\
**Post date:** [December 4, 2014, 4:40am UTC](https://discuss.elastic.co/t/what-would-be-the-effect-of-using-an-arbitrary-large-count/21074/1 "2014-12-04T04:40:04Z")

</div>

Hi  
We have a multi tenant SaaS solution and we expose our use of elasticsearch through an API. We noticed that clients who use the API directly, and not through our front-end, don't bother with paging and just use a count of 500k or 1m even if the actual count is much lower. I was wondering about the effect of not limiting the count since we're thinking of making a breaking change and limit this to 100.

Thanks for your help  
Ron

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/9507d1c8-5f32-41bf-a537-3cd4e0c2ba9c%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/9507d1c8-5f32-41bf-a537-3cd4e0c2ba9c%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![kazoompa\_3](https://avatars.discourse-cdn.com/v4/letter/k/958977/32.png) [@kazoompa\_3](https://discuss.elastic.co/u/kazoompa_3)\
**Post date:** [December 4, 2014, 1:42pm UTC](https://discuss.elastic.co/t/what-would-be-the-effect-of-using-an-arbitrary-large-count/21074/2 "2014-12-04T13:42:42Z")

</div>

I am still not expert an in ES but surely when not paging the process time  
will be higher because more documents have to be brought back in the  
response. However, depending on what kind of queries you perform, the  
subsequent queries will be faster. I am thinking of _filter bool queries_  
with caching and bitset query representation. I doubt that a size of _1m_  
will have any effect if there are only 100 documents indexed.

I wouldn't advise removing the paging for the sake of bandwidth and network  
traffic especially if you have many clients using the same server, may be a  
very optimized server setup can help.

We do a full query only when doing statistical calculation requiring all  
documents.

On Wednesday, December 3, 2014 11:40:05 PM UTC-5, Ron Sher wrote:

> Hi  
> We have a multi tenant SaaS solution and we expose our use of  
> elasticsearch through an API. We noticed that clients who use the API  
> directly, and not through our front-end, don't bother with paging and just  
> use a count of 500k or 1m even if the actual count is much lower. I was  
> wondering about the effect of not limiting the count since we're thinking  
> of making a breaking change and limit this to 100.
> 
> Thanks for your help  
> Ron

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/51e07a71-3649-4e99-9217-21b0f32b20b8%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/51e07a71-3649-4e99-9217-21b0f32b20b8%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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, 12:45am UTC](https://discuss.elastic.co/t/what-would-be-the-effect-of-using-an-arbitrary-large-count/21074/3 "2017-07-06T00:45:55Z")

</div>

Closed on July 6, 2017, 12:45am UTC


