英文:
add module "spring integration redis" which print out "XXX is not eligible for getting processed by all BeanPostProcessors
问题
我正在集成 Spring Integration Redis 模块,以便使用 RedisLockRegistry。但在 Spring Boot 启动时,我收到了以下日志:
19: 2020/09/11 21:02:25,006 2312 [INFO] [main] [integration.config.DefaultConfiguringBeanFactoryPostProcessor.registerErrorChannel(DefaultConfiguringBeanFactoryPostProcessor.java:213)] : 未明确定义名为 'errorChannel' 的 bean。因此,将创建一个默认的 PublishSubscribeChannel。
21: 2020/09/11 21:02:25,012 2318 [INFO] [main] [integration.config.DefaultConfiguringBeanFactoryPostProcessor.registerTaskScheduler(DefaultConfiguringBeanFactoryPostProcessor.java:300)] : 未明确定义名为 'taskScheduler' 的 bean。因此,将创建一个默认的 ThreadPoolTaskScheduler。
23: 2020/09/11 21:02:25,015 2321 [INFO] [main] [integration.config.DefaultConfiguringBeanFactoryPostProcessor.registerHeaderChannelRegistry(DefaultConfiguringBeanFactoryPostProcessor.java:460)] : 未明确定义名为 'integrationHeaderChannelRegistry' 的 bean。因此,将创建一个默认的 DefaultHeaderChannelRegistry。
25: 2020/09/11 21:02:25,073 2379 [INFO] [main] [context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker.postProcessAfterInitialization(PostProcessorRegistrationDelegate.java:335)] : 类型为 [org.springframework.integration.config.IntegrationManagementConfiguration] 的 bean 'org.springframework.integration.config.IntegrationManagementConfiguration' 无法被所有 BeanPostProcessors 处理(例如:不适合自动代理)。
27: 2020/09/11 21:02:25,115 2421 [INFO] [main] [context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker.postProcessAfterInitialization(PostProcessorRegistrationDelegate.java:335)] : 类型为 [org.springframework.integration.support.channel.BeanFactoryChannelResolver] 的 bean 'integrationChannelResolver' 无法被所有 BeanPostProcessors 处理(例如:不适合自动代理)。
29: 2020/09/11 21:02:25,119 2425 [INFO] [main] [context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker.postProcessAfterInitialization(PostProcessorRegistrationDelegate.java:335)] : 类型为 [org.springframework.integration.config.annotation.Disposables] 的 bean 'integrationDisposableAutoCreatedBeans' 无法被所有 BeanPostProcessors 处理(例如:不适合自动代理)。
1. 如何创建 errorChannel bean、taskScheduler bean 和 ThreadPoolTaskScheduler bean,以便我可以摆脱这些警告信息?
2. IntegrationManagementConfiguration、integrationChannelResolver 和 integrationDisposableAutoCreatedBeans 是否对我的应用程序造成问题?
3. 如何解决这些情况以消除上述日志?
英文:
I am integrating the spring integration-redis module so as to use the RedisLockRegistry. but I got the following logs on spring boot start up.
19: 2020/09/11 21:02:25,006 2312 [INFO] [main] [integration.config.DefaultConfiguringBeanFactoryPostProcessor.registerErrorChannel(DefaultConfiguringBeanFactoryPostProcessor.java:213)] : No bean named 'errorChannel' has been explicitly defined. Therefore, a default PublishSubscribeChannel will be created.
21: 2020/09/11 21:02:25,012 2318 [INFO] [main] [integration.config.DefaultConfiguringBeanFactoryPostProcessor.registerTaskScheduler(DefaultConfiguringBeanFactoryPostProcessor.java:300)] : No bean named 'taskScheduler' has been explicitly defined. Therefore, a default ThreadPoolTaskScheduler will be created.
23: 2020/09/11 21:02:25,015 2321 [INFO] [main] [integration.config.DefaultConfiguringBeanFactoryPostProcessor.registerHeaderChannelRegistry(DefaultConfiguringBeanFactoryPostProcessor.java:460)] : No bean named 'integrationHeaderChannelRegistry' has been explicitly defined. Therefore, a default DefaultHeaderChannelRegistry will be created.
25: 2020/09/11 21:02:25,073 2379 [INFO] [main] [context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker.postProcessAfterInitialization(PostProcessorRegistrationDelegate.java:335)] : Bean 'org.springframework.integration.config.IntegrationManagementConfiguration' of type [org.springframework.integration.config.IntegrationManagementConfiguration] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
27: 2020/09/11 21:02:25,115 2421 [INFO] [main] [context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker.postProcessAfterInitialization(PostProcessorRegistrationDelegate.java:335)] : Bean 'integrationChannelResolver' of type [org.springframework.integration.support.channel.BeanFactoryChannelResolver] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
29: 2020/09/11 21:02:25,119 2425 [INFO] [main] [context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker.postProcessAfterInitialization(PostProcessorRegistrationDelegate.java:335)] : Bean 'integrationDisposableAutoCreatedBeans' of type [org.springframework.integration.config.annotation.Disposables] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
1.how to create errorChannel bean, taskScheduler bean and ThreadPoolTaskScheduler bean so that I can get grid of these info like warning?
2.do the IntegrationManagementConfiguration, integrationChannelResolver and integrationDisposableAutoCreatedBeans cause problem to my application?
3.how to fixed these situation for the following logs?
答案1
得分: 0
这些只是INFO级别的日志消息。完全无害。您可能没有打开整个org.springframework
类别的INFO级别,以查看其他项目的类似消息。
实际上,前面的3条消息只是告诉我们默认的bean将被创建。不过,我们可能考虑将这些消息移动到DEBUG甚至TRACE级别...
对于IntegrationManagementConfiguration
的消息无关紧要,因为这是一个@Configuration
类,可能没有一个被“选中进行处理”。
最后一个关于Disposables
的消息也无关紧要,因为这个类是包级私有的,没有人真的会以某种方式对其进行后处理。
您日志中最令人担忧的是BeanFactoryChannelResolver
的那条消息,但只要您使用框架为您提供的任何内容,一切都会很好。
英文:
Those are just INFO log messages. Fully harmless. you probably didn't turn on the INFO for the whole org.springframework
category to see much more similar messages from other projects.
In fact the first 3 just say us that default bean are going to be created. We may consider to move those messages to the DEBUG or even TRACE level though...
The one for the IntegrationManagementConfiguration
doesn't matter because this one is a @Configuration
class and probably no one of them "is eligible for getting processed".
The last one for the Disposables
also doesn't matter since this class is package protected and no one really is going to post-process it somehow.
The most dangerous in your logs is that one for the BeanFactoryChannelResolver
, but as long as you use whatever the framework provides for you everything is going to be good.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论