简体   繁体   中英

elasticsearch: reindexing an index

I have an index which a few fields as keyword type. I need ot have these fields as text instead now.

Going through documentation , it seems to be not possible.

Documentation instead asks to create a new index and reindex it with documents from older index.

Can I keep new index name same as old one? Won't it cause issues during reindexing process?

no, you need to reindex to an index with a different name. One thing you could do, is to (1) reindex to eg original_index_name_v2 , (2) create an index alias named original_index_name catching original_index_name_* indices, (3) delete the original index. This way, next time you'll need to change the mapping, you don't need to change the index name but just keep querying the same alias

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM