perf: @Bean初始化优化, 以消除日志:is not eligible for getting processed by all BeanPostProcessors #608
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
由于Advisor会优先初始化,故相关@bean应加: @ROLE(BeanDefinition.ROLE_INFRASTRUCTURE) 以消除:is not eligible for getting processed by all BeanPostProcessors
去除@EnableConfigurationProperties(DynamicDataSourceProperties.class) 改为static方式配置是为了加@ROLE(BeanDefinition.ROLE_INFRASTRUCTURE)
spring 5.2+ 配置类如不内部不存在@bean方法引用应加: proxyBeanMethods = false 以去除不必要代理类 肖:ie:
@Configuration(proxyBeanMethods = false)
此PR是了消除启动时的以下日志:
What kind of change does this PR introduce? (check at least one)
The description of the PR:
@bean初始化优化, 以消除日志:is not eligible for getting processed by all BeanPostProcessors
Other information: