[BUG] SearchClient fails to delete scroll due to incorrect request path
Closed this issue · 1 comments
artemmukhin commented
Describe the bug
SearchClient.deleteScroll
method sends a DELETE request to an incorrect path: /scroll/<id>
instead of /_search/scroll/<id>
(see docs).
This also affects SearchClient.scroll(response: SearchResponse)
, which is expected to delete the scroll at the end by using SearchClient.deleteScroll
.
To Reproduce
- Call
SearchClient.deleteScroll(id)
- Call
SearchClient.scroll(id)
.
Expected: 404: No search context found for id
Actual: the next batch of search results is returned
Will you be able to help with a pull request?
I am going to open a PR that fixes the SearchClient.deleteScroll
implementation right away.
jillesvangurp commented
Thanks for this! Somehow this slipped through. I think searchAfter is recommended now, which is what I mostly use.