Fix settings for newly created incides
What does this MR do and why?
It turns out that we were merging all index settings, which caused this bug: gitlab-production index gets created with a sha... (#420347 - closed)
In this MR we update the elastic helper to use correct settings.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
| Before | After |
|---|---|
How to set up and validate locally
- Enable Advanced Search
- Checkout
master - Update number of shards for
gitlab-development, but keep it different from all other indices (for example, 10) - Execute
bin/rake gitlab:elastic:recreate_index - Ensure that
curl -s http://localhost:9200/gitlab-development/_settings | jq . | fgrep number_of_shardsreturns not the correct number of shards - Checkout this MR's branch
- Execute
bin/rake gitlab:elastic:recreate_index - Ensure that
curl -s http://localhost:9200/gitlab-development/_settings | jq . | fgrep number_of_shardsreturns the correct number of shards
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #420347 (closed)
Edited by Dmitry Gruzd