(一)开启自动配置
参考:
https://www.yuque.com/docs/share/9993e74c-db04-4d0f-8ab4-d32a30d9be4d?#
 
 
定期SpringBoot自动装配之后
 
ConfigurationClassParser#processImports  导入了AutoProxyRegistrar和ProxyTransactionManagementConfiguration
 
1.AutoProxyRegistrar作用
AutoProxyRegistrar作用注册InfrastructureAdvisorAutoProxyCreator到Spring容器里面,InfrastructureAdvisorAutoProxyCreator是AbstractAutoProxyCreator的子类,AbstractAutoProxyCreator又实现了BeanPostProcessor接口,那么在bean初始化完毕后就会调用postProcessAfterInstantiation()方法,postProcessAfterInstantiation()定义在AbstractAutoProxyCreator类中
 
 
每个bean实例化过程中都会走AbstractAutoProxyCreator的后置处理里面,如果存在advice,就会创建代理对象.
 
 
2.ProxyTransactionManagementConfiguration作用
 
 
