Managing index settings
Index settings are more important because they allow us to control several important ElasticSearch functionalities such as sharding/replica, caching, term management, routing, and analysis.
Getting ready
You will need a working ElasticSearch cluster and the index created in the Creating an index recipe in this chapter.
How to do it...
To manage the index settings, we will perform the steps given as follows:
To retrieve the settings of your current Index, the URL format is the following:
http://<server>/<index_name>/_settings
We are reading information via REST API, so the method will be GET, and an example of a call using the index created in the Creating an index recipe, is:
curl -XGET 'http://localhost:9200/myindex/_settings'
The response will be something similar to:
{ "myindex" : { "settings" : { "index" : { "uuid" : "pT65_cn_RHKmg1wPX7BGjw", "number_of_replicas" : "1", "number_of_shards" : "2", "version" : { ...