Elasticsearch PUT 插入数据
{
"error": {
"root_cause": [
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.atype_id] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
}
],
"type": "illegal_argument_exception",
"reason": "unknown setting [index.atype_id] please check that any required plugins are installed, or check the breaking changes documentation for removed settings",
"suppressed": [
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.id] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.name] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.package] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.rank] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.state] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
},
{
"type": "illegal_argument_exception",
"reason": "unknown setting [index.status] please check that any required plugins are installed, or check the breaking changes documentation for removed settings"
}
]
},
"status": 400
}
当出现 illegal_argument_exception 时候 意思是非法参数异常。也就是URI 缺少参数。在创建Elasticsearch的index 有一个 type (也就是Mysql数据中的表名), 在curl的时候没有输入这个type的话
就会报错
unknown setting [index.status] please check that any required plugins are installed, or check the breaking changes documentation for removed settings出现这个错误,这个错误就说明 你在插入数据的时候 不知道你要把你的这条数据插入到哪个表里面去,所以就报错了。类似于Mysql 因为要指定一张表的插入,不能随便插入不是。。。。
所以 正确的方法 URL 是
curl -H "Content-Type: application/json" -X PUT 'http://localhost:9200/index/type' -d
Elasticsearch PUT 插入数据的更多相关文章
- Elasticsearch教程(七) elasticsearch Insert 插入数据(Java)
首先我不赞成再采用一些中间件(jar包)来解决和 Elasticsearch 之间的交互,比如 Spring-data-elasticsearch.jar 系列一样,用就得依赖它.而 Elastic ...
- 第五篇 elasticsearch express插入数据
1.后端 在elasticsearch.js文件夹下添加: function addDocument(document) { return elasticClient.index({ index: i ...
- elasticsearch REST API方式批量插入数据
elasticsearch REST API方式批量插入数据 1:ES的服务地址 http://127.0.0.1:9600/_bulk 2:请求的数据体,注意数据的最后一行记得加换行 { &quo ...
- 使用Hive或Impala执行SQL语句,对存储在Elasticsearch中的数据操作(二)
CSSDesk body { background-color: #2574b0; } /*! zybuluo */ article,aside,details,figcaption,figure,f ...
- 使用Hive或Impala执行SQL语句,对存储在Elasticsearch中的数据操作
http://www.cnblogs.com/wgp13x/p/4934521.html 内容一样,样式好的版本. 使用Hive或Impala执行SQL语句,对存储在Elasticsearch中的数据 ...
- 用elasticsearch索引mongodb数据
参照网页:单机搭建elasticsearch和mongodb的river 三个步骤: 一,搭建单机replicSet二,安装mongodb-river插件三,创建meta,验证使用 第一步,搭建单机m ...
- 用Elasticsearch做大规模数据的多字段、多类型索引检索
本文同时发布在我的个人博客 之前尝试了用mysql做大规模数据的检索优化,可以看到单字段检索的情况下,是可以通过各种手段做到各种类型索引快速检索的,那是一种相对简单的场景. 但是实际应用往往会复杂一些 ...
- python批量插入数据到es和读取es数据
一.插入数据 1.首先准备类似如下数据 {"_type": "type1", "_id": 1, "_index": & ...
- 在ES批量插入数据超时时自动重试
当我们使用ES批量插入数据的时候,一般会这样写代码: from elasticsearch import Elasticsearch,helpers es =Elasticsearch(hosts=[ ...
随机推荐
- Python3---AJAX---爬虫
前言 该文章主要介绍面对AJAX的网页如何爬去信息,主要作用是适合刚入门爬虫查看学习 修改时间:20191219 天象独行 首先,我们先介绍一下什么是AJAX,AJAX是与服务器交换数据并跟新部分网页 ...
- centos 安装gitlab
1.开始安装依赖软件:yum -y install policycoreutils openssh-server openssh-clients postfix 2.设置postfix开机自启动,po ...
- django9-ajax
1.ajax 局部刷新 ,不可能每次提交请求刷新整个页面 2.ajax实例 在不刷新整个的情况下完成计算器 ,ajax的post需要添加csrftoken 1)设置一个组件ajaxcsrf.html ...
- 查找字段的筛选-使用addCustomView
关注本人微信和易信公众号: 微软动态CRM专家罗勇 ,回复231或者20161031可方便获取本文,同时可以在第一间得到我发布的最新的博文信息,follow me!我的网站是 www.luoyong. ...
- RunLoop的知识小记
RunLoop字面上的意思是,运行循环: 其基本作用:保持程序的持续运行: 处理App中的各种事件(比如:触摸事件.定时器事件.Selector事件) 节省CPU资源,提高程序性能:该做事时做事,该休 ...
- linux权限管理-基本权限
目录 linux权限管理-基本权限 权限修改命令chmod linux权限管理-基本权限 权限 针对某些文件和进程,对用户进行限制 权限与用户的关系 rwx rwx r-x User Group Ot ...
- Nginx的负载均衡算法、lvs的负载均衡算法
NGINX: 官方默认的算法: RR:轮询 weight:权重 ip_hash:配置此项后weight项失效 第三方模块: fair:根据后端服务器的繁忙程度 url_hash:如果客户端访问的url ...
- 3.Python爬虫入门_正则表达式(简单例子)
#2019-11-23 import requests import time import re #Python正则表达式库 if __name__=='__main__': #海量爬取图片数据 # ...
- 初学JavaScript正则表达式(十一)
JavaScript的对象属性 整理自慕课网教学 点此进入
- LG4824 「USACO2015FEB」(Silver)Censoring KMP+栈
问题描述 LG4824 题解 大概需要回顾(看了题解) KMP 先对要删除的 模式串 进行自我匹配,求出 \(\mathrm{fail}\) 然后再扫 文本串 的过程中记录一下每个字符匹配的最大长度, ...