Same scroll id

Hi There

I am running into a very strange issue, here is query

  1. first query
    http://localhost:9200/index/_search?scroll=1m&size=10

  2. next page
    http://localhost:9200/_search/scroll?scroll=1m&scroll_id=(Scroll ID from Above)

According to the documentation , i should get a new scroll id, but i keep getting the same scroll id, interestingly, the data coming back is indeed different for each request.

please advise

Thanks
Alps

In the case of a scrolling search, there is cluster-side state retained. It's very common for the scroll ID to remain the same on many sequential calls for the next group of results.

Nevertheless, you should always retrieve the value from the result, and use that value for the next call, because you never know when it's going to change.

Thank you for your reply