spring 的注解扫描时怎么生效的?
- <context:component-scan/> 里默认有<context:annotation-config/>
- 注解处理器
ConfigurationClassPostProcessor
AutowiredAnnotationPostProcessor
RequiredAnnotationBeanPostProcessor
CommonAnnotationBeanPostProcessor - 初始化调用顺序:@PostConstruct - > afterProperties -> init-method