Elasticsearch 和 MongoDB:5 次尝试后未找到 river _meta 文档

Elasticsearch and MongoDB: no river _meta document found after 5 attempts

我有一个名为 news 的 MongoDB 数据库,我试图用 ES 对其进行索引。 使用这些插件:

richardwilly98.elasticsearch/elasticsearch-river-mongodb/2.0.9elasticsearch/elasticsearch-mapper-attachments/2.5.0

这是我尝试创建索引时发生的情况。我试图删除索引并重新创建它,但没有帮助。

$ curl -XPUT 'http://localhost:9200/_river/news/_meta' -d @init.json

init.json

{
"type": "mongodb",
"mongodb": {
    "db": "news",
    "collection": "entries"
},
"index": {
    "name": "news",
    "type": "entries"
}
}

这里是日志

update_mapping [mongodb] (dynamic)
MongoDB River Plugin - version[2.0.9] - hash[73ddea5] - time[2015-04-06T21:16:46Z]
setRiverStatus called with mongodb - RUNNING
river mongodb startup pending
Starting river mongodb
MongoDB options: secondaryreadpreference [false], drop_collection [false], 
include_collection [], throttlesize [5000], gridfs [false], filter [null], 
db [news], collection [entries], script [null], indexing to [news]/[entries]
MongoDB version - 3.0.2
update_mapping [mongodb] (dynamic)
[org.elasticsearch.river.mongodb.CollectionSlurper] Cannot ..
  import collection entries into existing index
d with mongodb - INITIAL_IMPORT_FAILED
Started river mongodb
no river _meta document found after 5 attempts
no river _meta document found after 5 attempts

对可能出错的地方有什么建议吗? 我是 运行 ES 1.5.2MongoDB 3.0.2 OS X.

the mongodb river github pages 上,该插件似乎支持 1.4.2 版,但不支持更高版本(即您是 运行 1.5.2)

另请注意,河流已在 ES v1.5 中弃用,在 mongodb 河流项目中有一个关于这个主题的 open issue

与@martins

聊天后更新

最后,问题只是创建的河流名称错误(即 news 而不是 mongodb),以下命令将正确创建 mongodb 河流,即使没有经过官方测试,它仍然适用于 ES 1.5.2。

curl -XPUT 'http://localhost:9200/_river/mongodb/_meta' -d @init.json