본문 바로가기

SpringFramework Core - I. IoC 컨테이너/5. Bean Scopes

5.5. 커스텀 Scopes

원문: https://docs.spring.io/spring-framework/docs/current/spring-framework-reference/core.html#beans-factory-scopes-custom

 

 

bean의 scoping 메커니즘은 확장가능성이 있다. 나만의 scope를 만들수도 있으며 이미 존재하는 scope를 재정의할 수도 있다. 하지만 재정의는 그리 좋지 않으며, built-in된 싱글턴과 프로토타입 scope는 오버라이드 할 수 없다.