Re-index in ElasticSearch with zero downtime

0

Hi Everyone,

We use Elasticsearch 7.9, time to time we may need to do re-indexing. We are using aliases and the applications are pointing to alias instead of real index. I read some articles and it looks in most cases we would lose some update's/deletes that happen during the re-indexing process.

based on what I read, Below are the steps that I am planning to do.

Note : old_index is pointing to index-alias(it's alias name)

1- create new index(new_index) 2- do re-indexing from old_index to new_index 3- point the alias(index-alias) to new_index 4- Do second round of re-indexing from old_index to new_index

below are some of issues with this approach:

1- Two round of re-indexing needs to be done. This will become problematic, if we have large data in that index. 2- After step (3) , we may lose some of the deletes/updates on new_index.

What is the best method to do re-indexing with zero downtime and minimal impact for end-users?

Thanks in advance.

已提問 2 年前檢視次數 561 次
1 個回答
0

Does your data have any field to get the CDC like timestamp (for updated record) and id (for new record). If there is any field you can do the delta reindex on second iteration that will help speed up the second time reindex and will be way faster to sync the changes before you go live..

AWS
已回答 2 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南