elasticsearch 如何在Elasticsearch中滚动多搜索查询的结果?
我尝试了以下两种方法来滚动elasticsearch多搜索查询的结果 方法#1
elasticsearch 如何在Elasticsearch中滚动多搜索查询的结果?,
elasticsearch,
elasticsearch,我尝试了以下两种方法来滚动elasticsearch多搜索查询的结果 方法#1 curl -XGET "http://localhost:9200/indexname/_msearch?scroll=10m" -d' { "type": "parent" } {"query": {"match_all": {}}} { "type": "child" } {"query": {"match_all": {}}} ' 方法#2 curl -XGET "http://localhost:9200/
curl -XGET "http://localhost:9200/indexname/_msearch?scroll=10m" -d'
{ "type": "parent" }
{"query": {"match_all": {}}}
{ "type": "child" }
{"query": {"match_all": {}}}
'
方法#2
curl -XGET "http://localhost:9200/indexname/_msearch" -d'
{ "type": "parent", "scroll": "10m" }
{"query": {"match_all": {}}}
{ "type": "child", "scroll": "10m" }
{"query": {"match_all": {}}}
'
这两种方法似乎都不起作用,因为它们在响应中不返回滚动ID。我能做什么?我做错了什么?
提前谢谢 从和大小中签出
-这些可以与每个查询一起使用。例如:
{ "type": "parent" }
{ "from":20,"size":10, "query": {...}}
你成功完成了吗?-在多搜索中滚动?