适用于现有索引需要增加一个字段或修改类型
- 更新模板
PUT /_template/xxx - 建立新索引
PUT /xxx - 重建索引
POST _reindex
{
"source": {
"index": "old"
},
"dest": {
"index": "new"
}}
- 转移别名
POST /_aliases
{
"actions": [
{ "remove": { "index": "old", "alias": "xxx" }},
{ "add": { "index": "new", "alias": "xxx" }}
]}