You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/08/21 10:55:07 UTC

[GitHub] [shardingsphere] mumutu66 commented on issue #18093: ShardingSphereAlgorithmPostProcessor.init() not called

mumutu66 commented on issue #18093:
URL: https://github.com/apache/shardingsphere/issues/18093#issuecomment-1221521809

   I think  the datasource bean may not use the beanPostProcessor to init。。In some case other lib will use a beanPostProcessor which depends on  the datasource  will trigger the bean initialize during the `org.springframework.context.support.PostProcessorRegistrationDelegate#registerBeanPostProcessors(org.springframework.beans.factory.config.ConfigurableListableBeanFactory, org.springframework.context.support.AbstractApplicationContext)` and the datasource bean will missing the init phase . maybe use the `SmartInitializingSingleton` instead。。or just init right on the ` BeanDefinitionBuilder builder = BeanDefinitionBuilder.genericBeanDefinition(ShardingSphereAlgorithmFactory.createAlgorithm(algorithmConfig, algorithmClass).getClass());`  


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org