cmd下curl请求elasticsearch/eagles问题
2016-04-13 本文已影响89人
达贵
在window下安装了curl软件
cmd命令行:
curl -XPUT 192.168.0.200:17100/taskdispatch/warning/1111?pretty -d '{"assignment":["lisi"] }'
出现错误:
参考:http://www.webr2.com/elasticsearch-error-mapperparsingexception-failed-to-parse/
-Use double quotes for key:value. 用双引号键:值。
将命令改为:
curl -XPUT 192.168.0.200:17100/taskdispatch/warning/1111?pretty -d "{""assignment"":""lisi""}"
ok
D:\curl>curl -XPOST 192.168.0.200:17100/taskdispatch/warning/111?pretty -d "{\"assignment\":\"room\"}"
---------------------------------------------------------------------------------------------------
2016-04-13