LoginSignup
13
11

More than 5 years have passed since last update.

Elasticsearch無停止reindex

Last updated at Posted at 2015-03-13

使用する主な機能

  • aliasの指し先のatomicな変更
  • aliasの指し先の取得

手順(各indexについての処理)

登場するalias

  • write write用のalias
  • read read用のalias

初期状態でwriteとreadは同じindexを指しているとする

  1. old_index <- readの指すindex
  2. new_index <- 新たに作成したindex
  3. writeをold_indexからnew_indexを指すようにatomicに変更
  4. 全てのデータをwriteに対してindexする
  5. readをold_indexからnew_indexを指すようにatomicに変更

aliasを2つ使用する理由

reindex中に新たなデータが入った時に新しいindexに反映させるため

13
11
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
13
11