Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ public class StartupReporter {

public static final String SPRING_CONTEXT_BEAN_FACTORY_POST_PROCESSOR = "spring.context.bean-factory.post-process";

public static final String SPRING_CONFIG_CLASSES_ENHANCE = "spring.context.config-classes.enhance";

public static final Collection<String> SPRING_BEAN_INSTANTIATE_TYPES = Set
.of(SPRING_BEANS_INSTANTIATE,
SPRING_BEANS_SMART_INSTANTIATE);
Expand All @@ -61,6 +63,9 @@ public class StartupReporter {
.of(SPRING_CONTEXT_BEANDEF_REGISTRY_POST_PROCESSOR,
SPRING_CONTEXT_BEAN_FACTORY_POST_PROCESSOR);

public static final Collection<String> SPRING_CONFIG_CLASSES_ENHANCE_TYPES = Set
.of(SPRING_CONFIG_CLASSES_ENHANCE);

private final StartupStaticsModel startupStaticsModel;

private final List<BeanStatCustomizer> beanStatCustomizers;
Expand Down Expand Up @@ -216,7 +221,9 @@ public List<BeanStat> generateBeanStats(ConfigurableApplicationContext context)

private boolean filterBeanInitializeByCost(BeanStat beanStat) {
String name = beanStat.getType();
if (SPRING_BEAN_INSTANTIATE_TYPES.contains(name)) {
if (SPRING_BEAN_INSTANTIATE_TYPES.contains(name)
|| SPRING_CONTEXT_POST_PROCESSOR_TYPES.contains(name)
|| SPRING_CONFIG_CLASSES_ENHANCE_TYPES.contains(name)) {
return beanStat.getCost() >= costThreshold;
} else {
return true;
Expand Down