我正在搜索索引中的文档,然后尝试通过_id
获取其中的一些文档。尽管收到了一组结果,但有些文档无法通过简单的get获取。更糟糕的是,我可以使用?_id:<the id>
例如,运行一个简单的GET
curl -XGET 'http://localhost:9200/keepbusy_process__issuer_application/KeepBusy__Activities__Activity/neHSKSBCSv-OyAYn3IFcew'
给我结果:
{
"_index" : "keepbusy_process__issuer_application",
"_type" : "KeepBusy__Activities__Activity",
"_id" : "neHSKSBCSv-OyAYn3IFcew",
"exists" : false
}
但如果我使用相同的_id进行搜索:
curl -XGET 'http://localhost:9200/keepbusy_process__issuer_application/KeepBusy__Activities__Activity/_search?q=_id:neHSKSBCSv-OyAYn3IFcew'
我得到了预期的结果:
{
"took": 2,
"timed_out": false,
"_shards": {
"total": 5,
"successful": 5,
"failed": 0
},
"hits": {
"total": 1,
"max_score": 1.0,
"hits": [
{
"_index": "keepbusy_process__issuer_application",
"_type": "KeepBusy__Activities__Activity",
"_id": "neHSKSBCSv-OyAYn3IFcew",
"_score": 1.0,
"_source": {
"template_uid": "KeepBusy__Activities__Activity.create application",
"name": "create application",
"updated_at": "2014-01-08T10:02:33-05:00",
"updated_at_ms": 1389193353975
}
}
]
}
}
我正在通过担架ruby API索引文档,并在索引后立即进行刷新。我的本地设置是 2个节点。我正在运行 v0.90.9
日志中没有明显的原因,为什么会失败。我重新启动了群集,一切似乎都正常启动,但结果是一样的。
我有什么遗漏或某种方式可以进一步诊断这个问题吗?