title: Spring needs defining a bean, but bean is exists
body: <p>I have a spring-boot application with mongodb. I'm trying to add paging search capability. But a error happens:</p>
  <pre><code>Parameter 1 of constructor in com.life.library.adapter.port.out.mongo.MongoPortImpl required a bean of type 'com.life.library.adapter.port.out.mongo.repository.BookRepository' that could not be found.
  
  
  Action:
  
  Consider defining a bean of type 'com.life.library.adapter.port.out.mongo.repository.BookRepository' in your configuration.
  </code></pre>
  <p>My repositories:</p>
  <pre class="lang-java prettyprint-override"><code>public interface BookSearchRepository {
    Page&lt;BookDocument&gt; search();
  }
  
  @Repository
  public interface BookRepository
      extends PagingAndSortingRepository&lt;BookDocument, String&gt;, BookSearchRepository {
  }
  
  </code></pre>
  <p>Implementation of <code>BookSearchRepository</code> repository:</p>
  <pre class="lang-java prettyprint-override"><code>@Component
  @RequiredArgsConstructor
  public class BookSearchRepositoryImpl implements BookSearchRepository {
  
    private final MongoTemplate mongoTemplate;
  
    @Override
    public Page&lt;BookDocument&gt; search(){
      ...
    }
  }
  </code></pre>
  <p>Class, where I am trying to make autowaring of <code>BookRepository</code>:</p>
  <pre><code>@Component
  @RequiredArgsConstructor
  public class MongoPortImpl implements CreatePort, GetPort, SavePort {
  
    private final BookRepository bookRepository;
  }
  </code></pre>