Spring Data Rest & projections
<p>I want to return only a subset of my data to the client. i.e. use a projection. Some docs imply that a query can return a projection but I get the error shown below. If I change the query to return the supplier entity it all works fine.</p>

<p><code>java.lang.IllegalArgumentException: PersistentEntity must not be null!</code></p>

<p>The query: </p>

<p><code>Page&lt;SupplierLookupProjection&gt; 
findByApSupplierCodeContainsIgnoreCaseOrAdminAddressContainsIgnoreCaseOrderByApSupplierCodeAsc(Pageable pageable, @Param("code") String code, @Param("description") String description);
</code></p>

<p>The repository:</p>

<p><code>public interface SupplierRepository extends PagingAndSortingRepository&lt;Supplier, Long&gt;</code></p>