Closed
Description
Mark Paluch opened DATAMONGO-1464 and commented
Flip the order of data and count queries in paginated query execution to always request data and execute the count query conditionally. In case the data query returns a result that is neither 0 nor equals page size we don't need the count query as we can determine from the state that we hit the last page
Issue Links:
-
DATAJPA-912 Optimize out the count query for paging when the data query returns less than a full page with a 0 offset
-
DATACMNS-884 Move PageableExecutionSupport from JPA to Spring Data Commons
Referenced from: pull request #379