Elasticsearch aggregation performance

Hi,

I am trying to test aggregation performance across different ES topologies. The first time running it takes about 26 seconds, and all subsequent runs takes less than a second. I would like to compare performance for the first case.
I know there is a cache, and I run '_cache/clear' on all indices between runs. This has no effect. Is there another cache which is storing results causing the enhanced performance? Is there a way to clear this cache to compare the initial performance times?

Thanks

You probably want this:
https://www.elastic.co/guide/en/elasticsearch/reference/current/shard-request-cache.html#_enabling_and_disabling_caching_per_request

I use that to turn off the cache when I'm testing stuff. Keep in mind that it isn't really "fair" because you'll have it on in production. And it is possible to design your requests for higher cache hit rate. But disabling it is a useful test sometimes.

1 Like

I am still seeing the enhanced searching time even with '?request_cache=false'. Is there different behavior when searching using a wildcard? Ex: GET /my_indices_*/_search?request_cache=false

EDIT: Actually, this seems to work to not let entries in the cache in the first place. Seems that "_cache/clear" is not actually clearly the cache then.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.