# Proper indexing to improve query speed in elasticsearch

**URL:** <https://discuss.elastic.co/t/proper-indexing-to-improve-query-speed-in-elasticsearch/168019>\
**Category:** Elasticsearch\
**Created:** [February 12, 2019, 11:29am UTC](https://discuss.elastic.co/t/proper-indexing-to-improve-query-speed-in-elasticsearch/168019 "2019-02-12T11:29:09Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Praneet\_Khandelwal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/praneet_khandelwal/32/40565_2.png) [@Praneet\_Khandelwal](https://discuss.elastic.co/u/Praneet_Khandelwal)\
**Post date:** [February 12, 2019, 11:29am UTC](https://discuss.elastic.co/t/proper-indexing-to-improve-query-speed-in-elasticsearch/168019/1 "2019-02-12T11:29:09Z")

</div>

I am currently working on an ELK stack where we have a large number of documents (~50k in 1min) coming into our cluster. All the documents are coming from a bunch of log sources with a large number of fields. Currently all the documents go into a single index pattern because of which queries on the data take a long time to respond.  
Now, we have identified particular fields(eg: username, IP) in all log sources which are prominently used for querying the data.

1. I wanted to know how can I properly index the documents (using the above information )so that the response time is improved. (I would like to improve on this part more for our case.)
2. Also I was thinking of creating different indices for the various log sources which should help in improving the speed.

---

<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:** [March 12, 2019, 11:29am UTC](https://discuss.elastic.co/t/proper-indexing-to-improve-query-speed-in-elasticsearch/168019/2 "2019-03-12T11:29:12Z")

</div>

Closed on March 12, 2019, 11:29am UTC

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