AbstractApplicationContext 内建可查找的依赖

Bean 名称Bean 实例应用场景
environmentEnvironment 对象内部化配置以及 Profiles
systemPropertiesjava.util.Properties 对象Java 零碎属性
systemEnvironmentjava.util.Map 对象操作系统环境变量
messageSourceMessageSource 对象国际化文案
lifecycleProcessorLifecycleProcessor 对象Lifecycle Bean 处理器
applicationEventMulticasterApplicationEventMulticaster 对 象Spring 事件播送器

注解驱动 Spring 利用上下文内建可查找的依赖(局部)

Bean 名称Bean 实例应用场景
org.springframework.context.annotation.internalConfigurationAnnotationProcessorConfigurationClassPostProcessor 对象解决 Spring 配置类
org.springframework.context.annotation.internalAutowiredAnnotationProcessorAutowiredAnnotationBeanPostProcessor 对象解决 @Autowired 以及 @Value 注解
org.springframework.context.annotation.internalCommonAnnotationProcessorCommonAnnotationBeanPostProcessor 对象(条件激活)解决 JSR-250 注解,如 @PostConstruct 等
org.springframework.context.event.internalEventListenerProcessorEventListenerMethodProcessor 对象解决标注 @EventListener 的Spring 事件监听办法
org.springframework.context.event.internalEventListenerFactoryDefaultEventListenerFactory 对 象@EventListener 事件监听办法适配为 ApplicationListener
  1. ConfigurationClassPostProcessor--->BeanFactoryPostProcessor Spring容器的生命周期解决,BeanFactory后置处理器
  2. AutowiredAnnotationBeanPostProcessor--->BeanPostProcessor Bean的生命周期解决,Bean的后置处理器
  3. CommonAnnotationBeanPostProcessor--->BeanPostProcessor Bean的生命周期解决,Bean的后置处理器
  4. EventListenerMethodProcessor--->BeanFactoryPostProcessor pring容器的生命周期解决,BeanFactory后置处理器
  5. DefaultEventListenerFactory--->EventListenerFactory

原文: https://rumenz.com/rumenbiji/Spring-builds-lookup.html