Closed as not planned
Description
David Lopez opened SPR-15805 and commented
When you define a bean in a XML, you cannot redefine it in a @Component
or @TestComponent
class using a @Bean
declaration). It can, however, be redefined using another XML.
I have defined this as a Improvement since I do not think it explicitly violates anything .. simply it is a grey zone in the DI part fo Spring, but anyway, I consider this behaviour inconsistent and weird.
This issue is similar to #14201, but to the case when
Affects: 4.3.9, 5.0 RC2
Attachments:
- XmlOverrideBug.zip (5.35 kB)
Issue Links:
- Beans defined by @ComponentScan are skipped in @Configuration override [SPR-9567] #14201 Beans defined by
@ComponentScan
are skipped in@Configuration
override
1 votes, 1 watchers