Spring source code-the use of the seventh post processor

Processing of
the initialization method In this note, the use of the seventh post processor is recorded. This note will briefly summarize it.

  1. In the spring source code, three initialization methods are provided, and spring also specifies the priority of the three initialization methods: @PostConstruct> InitializingBean interface> init-method
  2. When the initialization method is called, only @PostConstruct is called in the seventh post processor. In fact, the logic is the same as the idea of ​​@Autowired. First find the annotated method, and then execute the corresponding method
  3. For the remaining two initialization methods, they are executed in the same method, and the order of execution is: the next method in the seventh post processor is to call the corresponding methods of the latter two initialization methods

Guess you like

Origin blog.csdn.net/CPLASF_/article/details/111966327