You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Suppose you have an application with a base package of com.acme with an @Configuration class located in this package. Now suppose you use this configuration class as basePackageClass inside @ComponentScan. This will result in an exception saying the class is registered twice. So you pretty much end up with always adding this exclude.
Would it make sense to default the excludeFilters attribute of the @ComponentScan annotation as follows?
@Filter(type = FilterType.ANNOTATION, value = Configuration.class)
This issue was actually addressed in #13450, and now available in RC2. Note particularly the resolution comment on that issue to understand the fix and why it doesn't require a default excludeFilters at all.
Activity
spring-projects-issues commentedon Nov 29, 2011
Chris Beams commented
Hi Ollie,
This issue was actually addressed in #13450, and now available in RC2. Note particularly the resolution comment on that issue to understand the fix and why it doesn't require a default
excludeFiltersat all.spring-projects-issues commentedon Nov 30, 2011
Oliver Drotbohm commented
Awesome, thanks! :)