# I can't do the best query in elasticSearch

**URL:** <https://discuss.elastic.co/t/i-cant-do-the-best-query-in-elasticsearch/224933>\
**Category:** Elasticsearch\
**Created:** [March 25, 2020, 2:47am UTC](https://discuss.elastic.co/t/i-cant-do-the-best-query-in-elasticsearch/224933 "2020-03-25T02:47:38Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![kang\_kang](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kang_kang/32/54479_2.png) [@kang\_kang](https://discuss.elastic.co/u/kang_kang)\
**Post date:** [March 25, 2020, 2:47am UTC](https://discuss.elastic.co/t/i-cant-do-the-best-query-in-elasticsearch/224933/1 "2020-03-25T02:47:39Z")

</div>

My configuration list 8c 32G \* 4 Data node 2c 4g \* 3 Master node 180w+ 32 fields doucument data in An index. One segment per node,Single fragmentation.Three copies in 4 Data node query Want to achieve the same effect as redis.

Simple query:  
 ![{CD60FC21-9673-452E-8DCE-D4DCFE5A7DAE}_20200325104854](https://us1.discourse-cdn.com/elastic/original/3X/8/e/8eac1cf2488a69434f8bf0a53df02a328772bca7.jpeg)

I can't keep the response time stable, like redis key value,It is possible to suddenly exceed 50ms. We allocate 60% of the heap to indices.fielddata.cache.size Each query has been preheated 256 query. For easy access indices.fielddata.cache.size segments Set to one.

---

<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:** [April 22, 2020, 2:47am UTC](https://discuss.elastic.co/t/i-cant-do-the-best-query-in-elasticsearch/224933/2 "2020-04-22T02:47:43Z")

</div>

Closed on April 22, 2020, 2:47am UTC

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