Recommended Pagination Method for Real-Time User Requests

Versions (relevant - OpenSearch/Dashboard/Server OS/Browser):
I think it’s OpenSearch 7.10.2

Describe the issue:
Hi all,

I’m building a feature to support real-time pagination for end users, and I need the pagination to be consistent across pages, even if documents are added or removed between user interactions.

I’ve been looking into using Point-In-Time (PIT) combined with search_after for this purpose. However, I’m unsure if this is the best approach for user-facing, real-time pagination scenarios.

Context

  1. The user should be able to paginate forward and backward, or even jump to arbitrary pages (e.g., from page 2 to page 15). Retrieving 20 items per page.
  2. The pagination must be consistent across the session — no missing or duplicated items, even if new documents are inserted or removed in the background.
  3. I’m considering setting the PIT keep_alive to around 10 minutes.
  4. The application has low concurrent usage (less than 30 users total in the worst case scenario).

Questions

  1. What happens if a user is on page 5 out of 30, and leaves for 15 minutes (exceeding the PIT keep_alive)? How can I handle this situation so they can resume pagination from where they left off?
  2. What is the recommended PIT keep_alive duration for this kind of usage?

Any guidance or experience would be much appreciated, Thank you.