In this chapter, we have covered the bottlenecks of Elasticsearch performance and how to improve it. We started with data sparsity and explained the reason for sparsity and how it impacts performance. After sparsity, we covered and explained different solutions to common problems. We explained stemming with examples and, after that, explained inconsistent scoring. We explained different ways to tune the indexing speed, such as bulk requests, smart use of Elasticsearch clusters, increasing refresh intervals, and disabling refresh and replicas. Then, we also covered how to tune search speed through allocating memory to the filesystem cache, faster hardware, document modeling, pre-index data, avoiding replicas, and so on. Finally, we covered how to tune search queries with the Profile API and how to tune for disk usage.
In the next chapter, we will cover how to aggregate...