Problem Statement
Since we are moving to multi index format and static mapping there should be a way in accordance with CI/CD to update mapping whenever a new field is added as required.
Solution Approach
A jenkins job can be added to update mapping for indexes. The jenkins needs to be configured to perform below steps
- verify if the index exists or not?
- if index does not exists, create index with create file.
- If index is available it calls the update mapping.
Problem Statement
How to verify if an index exists or not
Solution Approach
A HEAD http call can be used to verify if index exists or not
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
Request
HEAD /{indexName}
Response status code with details
200 - index exists
404 - index missing
|