Closed
Description
Oliver Drotbohm opened SPR-11718 and commented
Overriding an @Bean
method with a narrowed return type is working fine with Spring 3.2.8 on legacy JDKs (6 and 7). However, it's breaking with Spring 3.2.8 on JDK 8. Spring 4.0 on JDK 8 fixes this already, as part of general @Bean
overload support. For Spring 3.2.9, we should do a minimal fix for the regression on JDK 8, even if we're not allowing overloaded @Bean
methods in the same class yet.
Affects: 3.2.8
Issue Links:
- ConfigurationClass.validate() should allow for overloading in general or not at all [SPR-11025] #15653 ConfigurationClass.validate() should allow for overloading in general or not at all
- Metadata reading should never use ASM for java.* and javax.* types (in particular on JDK 8) [SPR-11719] #16341 Metadata reading should never use ASM for java.* and javax.* types (in particular on JDK 8)
Backported to: 3.2.9