Hello All,
I am looking for a solution for scenario where need to change data type of field.
We configure index using index mapping template and reindexing is done whenever there is any change in index mapping. We are using Elasticsearch 6.8.8
-
Current mapping
"applicationType": { "type": "text", "index" : false }
-
Expected new mapping
"applicationType.code": { "type": "keyword", "index": false }, "applicationType.value": { "type": "text", "index": false },
How can I support smooth migration?
- I do not want to lose old data
- I want to manually copy from old field value to new structure
For ex,applicationType -> applicationType.code
I tried with alias option, it does not give expected result. Already went through definitive guide. Major challenging requirement is to support the same field name in json message "applicationType" for new mapping.
It's okay to use different name for old field, but do not want to loose data.
I hope there is a solution for this,
I will appreciate clean solution.