title: Can we create custom Query using Spring Data REST while using @RepositoryRestResource?
body: <p>I am new to spring boot, I was trying to create a simple REST service using Spring-boot JPA. First I used simple <code>@Repository</code> which works fine, I can write custom Query method for the properties defined in my class. But when I use <code>@RepositoryRestResource</code> I am not able to create custom Query methods. Basic finding on  primary key and other operations are happening but I can not create any custom Query. </p>
  
  <pre><code>package com.example.demo.Model;
  
  import javax.persistence.Entity;
  import javax.persistence.GeneratedValue;
  import javax.persistence.Id;
  
  @Entity
  public class Book {
  
      @Id
      @GeneratedValue
      int id;
      int isbn;
      String name;
      String author;
      double price;
      public int getId() {
          return id;
      }
      public void setId(int id) {
          this.id = id;
      }
      public int getIsbn() {
          return isbn;
      }
      public void setIsbn(int isbn) {
          this.isbn = isbn;
      }
      public String getName() {
          return name;
      }
      public void setName(String name) {
          this.name = name;
      }
      public String getAuthor() {
          return author;
      }
      public void setAuthor(String author) {
          this.author = author;
      }
      public double getPrice() {
          return price;
      }
      public void setPrice(double price) {
          this.price = price;
      }
  
  }
  </code></pre>
  
  <p>This is Repository</p>
  
  <pre><code>package com.example.demo.repo;
  
  import java.util.List;
  
  import org.springframework.data.jpa.repository.JpaRepository;
  import org.springframework.data.jpa.repository.Query;
  import org.springframework.data.repository.query.Param;
  import org.springframework.data.rest.core.annotation.RepositoryRestResource;
  import org.springframework.stereotype.Repository;
  
  import com.example.demo.Model.Book;
  
  @RepositoryRestResource(collectionResourceRel = "books", path = "books")
  public interface BookRepo extends JpaRepository&lt;Book, Integer&gt; {
  
      //I want this query to work same as it does for primary Key id.
      public Book findByName(@Param("name") String name);
  
      //Same for this
      public Book findByIsbn(@Param("isbn") String isbn);    
  
  }
  </code></pre>
  
  <p>Since I am not mapping any url for searching by name, I am trying to search like this <code>localhost:8080/books/?name=java</code> Is it correct?
  For above url it simply behaves like <code>localhost:8080/books</code> and ignore subsequent part and provides all books details.
   I just want to have two classes and perform all basic rest operation and create custom Query. </p>
  
  <p>Thank you in advance.</p>