I answer from ndb promising, I do not use the search API. All quotes from your first link.
For 1 and 3 (since the order is considered part of the initial request from prospective cursors):
To get additional results from the cursor point, the application prepares a similar query with the same type of entity, filters and sort orders, and passes the cursor to the with_cursor () query before doing the search
Thus, it doesnβt really matter how old the cursor is (i.e. how old the query is), since its original query must be restored to get the cursor.
For 2:
Cursors and data updates
The cursor position is defined as the location in the result list after the last result is returned. The cursor is not a relative position in the list (this is not an offset); This is a marker that cloud storage can jump to when starting an index scan for results. If the results for a query change between use of the cursor, the changes in the query change which appear in the results after the cursor. If a new cursor position result for a query has appeared, it will not be returned when the results are after selecting a cursor. Similarly, if the entity is not a longer result for the query, but appears before the cursor, the results that appear after the cursor does not change. If the last result returned is removed from the result set, the cursor still knows how to find the next result.
When retrieving query results, you can use either the start cursor or end to return a continuous group of results from the Cloud Data Warehouse. When using the start and end cursor to get results, you are not guaranteed that the size of the results will be the same as when creating cursors. Objects can be added or removed from the cloud data store between the moment the cursors are created and when they are used in the query.
The Java Cursor Limitations equivalent page mentions some errors that might be raised for inconsistencies:
Newer versions of App Engine may change the internal implementation details, invalid cursors that depend on them. If an application tries to use a cursor that is no longer valid, Cloud Datastore raises an IllegalArgumentException (low level API), JDOFatalUserException (JDO), or PersistenceException (JPA).
I suspect Python will also raise some similar errors.
Dan cornilescu
source share