注:SpringFramework的版本是4.3.x。git
咱们分析的是scope为singleton的bean,beanFactory.getBean时的流程,scope为prototype的处理流程与singleton的不一样。github
原图在Github上,图内容有点多,建议读者查看原图。spa
图1 scope为singleton的bean,beanFactory.getBean的时序图prototype