title: Auto-wiring generic dependency to a specific type
body: <p>I have a class like this,</p>
  
  <pre><code>@Component
  class GenericRepositoryModel&lt;T&gt;
  {
  //.,..
  }
  </code></pre>
  
  <p>In my code, I have to use for a specific type,</p>
  
  <pre><code>@Controller
  class WebController
  {
  @Autowired
  private GenericRepositoryModel&lt;Type1&gt; customerRepository;
  
  }
  </code></pre>
  
  <p>But when I try to do the above, I am getting the below exception. </p>
  
  <blockquote>
    <p>Field customerRepository in com.sbexample.springbootdemo.WebController
    required a bean of type
    'com.sbexample.springbootdemo.GenericRepositoryModel' that could not
    be found. Consider defining a bean of type
    'com.sbexample.springbootdemo.GenericRepositoryModel' in your
    configuration.</p>
  </blockquote>
  
  <p>What's the right way of doing it?</p>
  
  <p>BTW, I am using Spring 4.3.16 via Spring boot 1.5.10.</p>