问题是您丢失了,
document type并且
document id在通过
PUThttp://localhost:9200/aws命令索引文档时。
索引文档的正确方法是:
POST my-index/my-type/my-id-1{ "name": "kibana"}即,您必须提供
document type(此处为my-type)和
document id(此处为my-
id-1)。请注意,此处的文档ID是可选的,因此,如果您不提供文档ID,则elasticsearch为您创建一个字母数字ID。
索引文档的其他几种方法:
POST my-index/my-type{ "name": "kibana"}//if you want to index document through PUT then you must provide document idPUT my-index/my-type/my-id-1{ "name": "kibana"}注意: 如果禁用了自动索引创建,则必须在索引文档之前创建索引。



