Do not consider all @Components as configuration
Update ConfigurationClassUtils to only consider beans with @Bean methods as 'lite' configuration candidates. Prior to this commit all @Component beans were considered 'lite' configuration candidates which could result in a large number of ConfigurationClass instance being created that would ultimately be ignored. Issue: SPR-10609
This commit is contained in:
@@ -16,9 +16,15 @@
|
||||
|
||||
package org.springframework.context.annotation.componentscan.simple;
|
||||
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@Component
|
||||
public class SimpleComponent {
|
||||
|
||||
@Bean
|
||||
public String exampleBean() {
|
||||
return "example";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user