-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Description
hello,
i scoured the documentation and even used LLMs to search for an answer (sick!), but i found nothing.
the main point is - i'm trying to implement keyset pagination. is it possible to define such a repository interface method?
List<Entity> findAllBy(Specification<Entity> specification, Sort sort, Limit limit);
the where condition is in the specification, ordering and limiting need to go along. i don't want to use Pageable
in order not to have the extra count query executed, since that defeats the point. and if it's true that Limit
is converted to Pageable
under the hood, then it's not the way to go anyway.
another option would be perhaps dynamic limit value, but from what i see it's not possible as well?
is there a way to implement proper keyset pagination with Spring Data that i don't see, aside from implementing a custom repository?