Page has an incorrect total since 3.4.3 #3802
Labels
status: waiting-for-feedback
We need additional information before we can continue
status: waiting-for-triage
An issue we've not yet triaged
We are using spring-data-jpa to perform a query using a JpaRepository that returns a Page object. I am seeing different behaviour with spring-data-jpa 3.4.2 compared to spring-data-jpa 3.4.3.
Use-case
3.4.2
3.4.3
I could not find anything in the release notes, and in my (not-so-informed) opinion the behaviour in 3.4.2 makes more sense. This feels like a bug to me.
I would appreciate any response, whether it's an explanation why this new result is better or whether it's a confirmation that I've indeed found a bug.
If this issue is not according to your standards, please let me know.
Edit
SimpleJpaRepository.readPage() returns a total of 44 independent of the specified page number (i.e. is correct).
JpaQueryExecution.doExecute() returns a total of 20/40/44 depending on the page number (i.e. is incorrect).
One of our endpoints does the search via a .findAll() call on a JpaRepository, which will trigger the SimpleJpaRepository.readPage() call, while another endpoint of us does the search via a custom method annotated with @query on a JpaRepository, which will trigger the JpaQueryExecution.doExecute().
Hopefully this helps. It helped me see that we have a possible work-around, though I still think there is a bug that should be resolved.
The text was updated successfully, but these errors were encountered: