title: Can't create custom query method in Spring Data Repository
body: <p>I wanted to create custom repository : </p>
  
  <pre><code>public interface FriendRepositoryCustom {
  
      Page&lt;Friend&gt; findFriends(FriendCriteria friendCriteria, Pageable pageable);
  }
  </code></pre>
  
  <p>And its implementation : </p>
  
  <pre><code>@Repository
  @Transactional(readOnly = true)
  public class FriendRepositoryCustomImpl implements FriendRepositoryCustom {
  
      @PersistenceContext
      EntityManager entityManager;
  
      @Override
      public Page&lt;Friend&gt; findFriends(FriendCriteria friendCriteria, Pageable pageable) {
      ...
      }
  </code></pre>
  
  <p>And added it to main repository :</p>
  
  <pre><code>@Repository
  public interface FriendRepository extends JpaRepository&lt;Friend, Long&gt;, JpaSpecificationExecutor&lt;Friend&gt;, FriendRepositoryCustom {
  
  }
  </code></pre>
  
  <p>When i start application i get this error : </p>
  
  <blockquote>
    <p>Caused by:
    org.springframework.data.mapping.PropertyReferenceException: No
    property findFriends found for type Friend!   at
    org.springframework.data.mapping.PropertyPath.(PropertyPath.java:77)
      at
    org.springframework.data.mapping.PropertyPath.create(PropertyPath.java:329)
      at
    org.springframework.data.mapping.PropertyPath.create(PropertyPath.java:309)
      at
    org.springframework.data.mapping.PropertyPath.from(PropertyPath.java:272)
      at
    org.springframework.data.mapping.PropertyPath.from(PropertyPath.java:243)
      at
    org.springframework.data.repository.query.parser.Part.(Part.java:76)
      at
    org.springframework.data.repository.query.parser.PartTree$OrPart.(PartTree.java:247)
      at
    org.springframework.data.repository.query.parser.PartTree$Predicate.buildTree(PartTree.java:398)
      at
    org.springframework.data.repository.query.parser.PartTree$Predicate.(PartTree.java:378)
      at
    org.springframework.data.repository.query.parser.PartTree.(PartTree.java:86)
      at
    org.springframework.data.jpa.repository.query.PartTreeJpaQuery.(PartTreeJpaQuery.java:70)
      ... 43 common frames omitted</p>
  </blockquote>