[ElasticSearch] alias API 요청으로 별칭 생성

Woong·2023년 3월 8일
0

ElasticSearch

목록 보기
17/21
  • ElasticSearch ILM 을 통해 index 에 alias 를 걸 수 있지만
  • 직접 alias API 를 통해 alias 를 생성해야할 때도 있을 것이다.
  • ex) curl -X POST 'http://localhost:9200/_aliases' --user test_user:test_password -H 'Content-type: application/json' -d '{"actions":[{"add":{"index":"my_test_index_v1","alias":"my_index"}}]}'

  • actions 가 remove 일 경우 alias 를 삭제

reference

0개의 댓글