The store type
Elasticsearch exposes five store types that we can use. By default, Elasticsearch picks the best implementation based on the operating system environment. But you can override the default behavior in following ways:
The first way, is to set for all the indices, by adding the
index.store.typeproperty inside theelasticsearch.ymlfile. For example, if you want to set theniofsstore type to all the indices you can add following line insideelasticsearch.ymlfile:
index.store.type: niofs
The second way is to set per index at the index creation time in the following way:
curl -XPUT "http://localhost:9200/index_name" -d' { "settings": { "index.store.type": "niofs" } }'
Let's see what these store types provide and how we can leverage their features.
The simple file system store - simplefs
The simplest implementation of the Directory class that is available is implemented using a random access file (Java RandomAccessFile—http://docs.oracle.com/javase/8/docs/api/java/io...