[英]Why does this ElasticSearch scan and scroll returns IndexMissingException
我运行以下命令:
curl -XGET 'http://my_address/my_index/_search?scroll=1m&size=10&search_type=scan' -d '{'query':{'match_all':{}}}'
它返回一个滚动id(很长),然后在第一个滚动请求中使用:
curl -XGET 'http://my_address/my_index/_search/scroll?scroll=1m' -d '<scroll_id>'
它返回错误:{“错误”:“ IndexMissingException [[my_index]丢失]”,“状态”:404}
我不知道为什么会有这个错误。 我会逐步遵循https://www.elastic.co/guide/zh-CN/elasticsearch/reference/current/search-request-scroll.html中的指南。
到底是怎么回事?
因为您的第二个请求(即使用scroll_id
)不应获取任何索引,而是这样读取:
curl -XGET 'http://my_address/_search/scroll?scroll=1m' -d '<scroll_id>'
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.