I have around 20 million documents in my ES index with 3 shards and a single node.
I have 15 fields out of which I want to perform search on only 5 fields.
So, I have kept those 5 fields as 'index: not_analyzed' and field data settings are kept as 'loading:eager'.
I don't want to perform any kind of sorting or aggregation or scoring on the results.
The rest of the 10 fields are kept as 'enabled:false' since I just want to retrieve those fields in my output.
When I start the bulk search operation on all the 5 fields, it takes a lot of time to search.
In some cases, we have noticed that the speed of search increases after some time (approx half an hour).
Can you help me why it takes so much time to search?
Is it better to use field data or doc_values (as specified in the ES doc - https://www.elastic.co/blog/support-in-the-wild-my-biggest-elasticsearch-problem-at-scale)
And there is also an option where we can keep the 'doc_values: true' along with 'field data loading: eager' and 'field data format: disabled' at the same time? Since field data loads all the data in memory and doc_values store the data in disk, how does this combination work?
Thanks in advance.