1public interface PersonRepository extends PagingAndSortingRepository<Person, String> {
2
3 List<Person> findByLastname(String lastname);
4
5 Page<Person> findByFirstname(String firstname, Pageable pageable);
6
7 Person findByShippingAddresses(Address address);
8
9}
1public interface PersonRepository extends MongoRepository<Person, String>
2// Geo-spatial repository queries
3 // { 'location' : { '$near' : [point.x, point.y], '$maxDistance' : distance}}
4 List<Person> findByLocationNear(Point location, Distance distance);
5}