Global index settings

I want to apply some global index settings (index.number_of_replicas, index.codec) to any new created index.

From Index settings in configuration file does not take effect I understand that configuraiton of global index settings in elasticsearch.yml has been deprecated and is not supported, so I have to create an index template.

Should I create an "*" index template that matches all indexes? Is it valid to match all indexes?

What if multiple index templates match the new index (my global index template + other)?
Docs say: "If a new data stream or index matches more than one index template, the index template with the highest priority is used."
Then if my global index template is applied, other index template settings are lost....

Docs include info about template components used to create a composite index template.
The workaround may be to create component templates and modify existing index templates to include my component template that includes my settings.
This is very tedious, time consuming, and complex (easily buggy) as compared to the previous simple method of defining global index settings in elasticsearch.yml.

The index template seems a bad alternative. They may allow more control over settings but are hard to use.

Additional sources:

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