In order to make common use cases like finding the record with the biggest or smallest property value and finding the top K customers based on customer value
we should provide a way to express those queries via the query derivation mechanism.
This could look like the following:
(Entity, Optional<Entity>, Iterable<Entity>, Collection+<Entity>) findFirstNByAAA...
For N = 1: we allow the following return types:
(Note that findFirstBy will be handled as findFirst1By)
and for N > 1:
Note that instead of the First keyword one could also use the Top keyword.
This would enable us to do the following: