Difference between @EntityScan and @ComponentScan
<p>I am trying to understand the difference here. I see that a class has been annotated with both of them with same package example :</p>

<pre><code>@Configuration
@EntityScan("some.known.persistence")
@ComponentScan({ "some.known.persistence"})
public class ApiConfig {

}
</code></pre>

<p>I understand the differences from API docs but want to understand in detail. Also does it mean that anything that is scanned by <code>@ComponentScan</code> is having wider visibility wrt Spring context and <code>@EntityScan</code> does not. If so using some attribute with <code>@ComponentScan</code> should have sufficed the need to bind in a JPA context, isn't it?</p>