Skip to the content.

%[https://gist.github.com/osk2090/aa540b05131757e25177930c4ef05f1e]

해당 코드를 출력해보면

==============================================
빈의 개수: 5
org.springframework.context.annotation.internalConfigurationAnnotationProcessor = org.springframework.context.annotation.ConfigurationClassPostProcessor
org.springframework.context.annotation.internalAutowiredAnnotationProcessor = org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor
org.springframework.context.annotation.internalCommonAnnotationProcessor = org.springframework.context.annotation.CommonAnnotationBeanPostProcessor
org.springframework.context.event.internalEventListenerProcessor = org.springframework.context.event.EventListenerMethodProcessor
org.springframework.context.event.internalEventListenerFactory = org.springframework.context.event.DefaultEventListenerFactory
==============================================

총 5개의 객체(빈)이 자동으로 생성되는것을 볼 수 있다.

(@postConstruct

이벤트리스너 메서드를 개별적으로 애플리케이션 인스턴스로 등록한다.

(해당 코드에 이벤트리스너를 심어놓으면 설정한 코드대로 출력을 해주거나 동작한다.)

출처: https://goddaehee.tistory.com/46 [갓대희의 작은공간]

https://m.blog.naver.com/PostView.naver?isHttpsRedirect=true&blogId=javaking75&logNo=220728817382