Scroll id questions

Hi.

I'm using scroll to export data from es 5.0.0, and I have a few questions:

  1. The reference says:
    "The initial search request and each subsequent scroll request returns a new _scroll_id — only the most recent _scroll_id should be used."

While in test, the initial search request and each subsequent scroll request returns the same _scroll_id.

  1. When I try to clear scroll:
DELETE /_search/scroll
{
    "scroll_id" : "DnF1ZXJ5VGhlbkZldGNoFAAAAAAAG3Z7FmtGVmdXb2RKUzUyaGZ0dkxLajJxUWcAAAAAAACcnxZ6ZWdHMWw3alRQeXZ0UHllN2czblJRAAAAAAAOEpMWZ1hZZG5odVNSdy01TG40dFBzc2JWZwAAAAAADhKPFk9PTThraVZ2UXF5S2xETVJwYVdnbXcAAAAAAAC--BZ0VEJvMTBHbVNxZTgwNEtzSExZNVh3AAAAAAAbdnwWa0ZWZ1dvZEpTNTJoZnR2TEtqMnFRZwAAAAAAAJygFnplZ0cxbDdqVFB5dnRQeWU3ZzNuUlEAAAAAAA4SlBZnWFlkbmh1U1J3LTVMbjR0UHNzYlZnAAAAAAAOEpAWT09NOGtpVnZRcXlLbERNUnBhV2dtdwAAAAAAAL75FnRUQm8xMEdtU3FlODA0S3NITFk1WHcAAAAAABt2fRZrRlZnV29kSlM1MmhmdHZMS2oycVFnAAAAAAAAnKEWemVnRzFsN2pUUHl2dFB5ZTdnM25SUQAAAAAADhKVFmdYWWRuaHVTUnctNUxuNHRQc3NiVmcAAAAAAA4SkRZPT004a2lWdlFxeUtsRE1ScGFXZ213AAAAAAAAvvoWdFRCbzEwR21TcWU4MDRLc0hMWTVYdwAAAAAAG3Z-FmtGVmdXb2RKUzUyaGZ0dkxLajJxUWcAAAAAAACcohZ6ZWdHMWw3alRQeXZ0UHllN2czblJRAAAAAAAOEpYWZ1hZZG5odVNSdy01TG40dFBzc2JWZwAAAAAADhKSFk9PTThraVZ2UXF5S2xETVJwYVdnbXcAAAAAAAC--xZ0VEJvMTBHbVNxZTgwNEtzSExZNVh3"
}

I always get the following:

{
"error": {
"root_cause": [
{
"type": "action_request_validation_exception",
"reason": "Validation Failed: 1: no scroll ids specified;"
}
],
"type": "action_request_validation_exception",
"reason": "Validation Failed: 1: no scroll ids specified;"
},
"status": 400
}

Need I clear the last scroll id after each subsequent scroll request?
Any help would be appreciated!

Nope, requesting the new ID auto clears the old one.

Thanks very much!
Hope the reference can be more clearly : )

I raised https://github.com/elastic/elasticsearch/pull/24204 to clarify :slight_smile:

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.