title: @ComponentScan does not exist in org.springframework.context.annotation package
body: <p>I am new spring framework, and i was practicing of java Configuration(No XML) </p>
  
  <p>In this example I had need @Configuration and @ComponentScan(), which should be present in <code>org.springframework.context.annotation</code> package but in this package @Configuration is available but @ComponentScan is not. </p>
  
  <p>Whenever i am trying to use @ComponentScan  eclipse suggests me to import @ComponentScan from <code>org.springframework.config.java.plugin.context</code> package which is not working properly. </p>
  
  <p>When importing</p>
  
  <blockquote>
    <p>org.springframework.config.java.plugin.context.ComponentScan</p>
  </blockquote>
  
  <p>I get the following error.</p>
  
  <pre><code>Exception in thread "main" org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'name' is defined
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/2yqwK.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/2yqwK.png" alt="NoXmlConfig.java"></a>
  <a href="https://i.stack.imgur.com/NV1XP.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/NV1XP.png" alt="&lt;code&gt;org.springframework.context.annotation&lt;/code&gt; package"></a></p>