1. 程式人生 > >源碼解析:init-method、@PostConstruct、afterPropertiesSet孰先孰後

源碼解析:init-method、@PostConstruct、afterPropertiesSet孰先孰後

tro strong proc blog tor after stc ini 解析

http://sexycoding.iteye.com/blog/1046993

@PostConstruct註解後的方法在BeanPostProcessor前置處理器中就被執行了,所以當然要先於InitializingBean和init-method執行了。

Constructor > @PostConstruct > InitializingBean > init-method

源碼解析:init-method、@PostConstruct、afterPropertiesSet孰先孰後