笔记:remote reindex无法从ES7-->ES6

背景

测试经常使用reindex API,一般都是同版本或者升级版本使用;

使用

remote reindex

复制代码
POST _reindex
{
  "conflicts": "proceed",
  "source": {
    "remote": {
      "host": "http://xxx.com:80",
      "username": "elastic",
      "password": "xxxxx",
      "headers": {
        "x-client-app": "12345"
      }
    },
    "index": "test",
    "size": 1000,
    "query": {
      "match_all": {}
    }
  },
  "dest": {
    "index": "test"
  }
}

发现报错

复制代码
{
  "error": {
    "root_cause": [
      {
        "type": "exception",
        "reason": "Error parsing the response, remote is likely not an Elasticsearch instance"
      }
    ],
    "type": "exception",
    "reason": "Error parsing the response, remote is likely not an Elasticsearch instance",
    "caused_by": {
      "type": "x_content_parse_exception",
      "reason": "[1:242] [search_response] failed to parse field [hits]",
      "caused_by": {
        "type": "x_content_parse_exception",
        "reason": "[1:242] [hits] total doesn't support values of type: START_OBJECT"
      }
    }
  },
  "status": 500
}

原因:remote reindex无法从ES7同步数据到ES6(不能降级)

相关推荐
jack_xu8 分钟前
高频面试题:如何保证数据库和es数据一致性
后端·mysql·elasticsearch
技术项目引流23 分钟前
elasticsearch查询中的特殊字符影响分析
大数据·elasticsearch·搜索引擎
YuCaiH43 分钟前
数组理论基础
笔记·leetcode·c·数组
bicijinlian2 小时前
多语言笔记系列:使用导入魔法命令
笔记
foo1st4 小时前
JDK(Ubuntu 18.04.6 LTS)安装笔记
java·笔记·ubuntu
DKPT4 小时前
常见正则表达式整理与Java使用正则表达式的例子
java·笔记·学习·面试·正则表达式
下雨的Jim4 小时前
前端速成之——Script
前端·笔记
爱码小白4 小时前
wordpress学习笔记
笔记·学习
我的golang之路果然有问题5 小时前
快速上手GO的net/http包,个人学习笔记
笔记·后端·学习·http·golang·go·net
大溪地C5 小时前
HTML5 详细学习笔记
笔记·学习·html5