Spring Framework 이용해 2개 이상의 웹 프로젝트를 배포할 경우 Log4jConfigListener에 대한 예외가 발생할 수 있다.
(org.springframework.web.util.Log4jConfigListener를 이용해 log4j.properties를 로딩할 경우)
Log4jConfigListener 컨텍스트 초기화 예외 발생
예외 내용:
java.lang.IllegalStateException
Web app root system property already set to different value:
- Choose unique values for the 'webAppRootKey' context-param in your web.xml files!
Web app root system property already set to different value:
- Choose unique values for the 'webAppRootKey' context-param in your web.xml files!
해결 방법:
컨텍스트 파라미터webAppRootKey의 값을 설정해준다. webAppRootKey의 디폴트 값은 webapp.root임
예)<context-param>
<param-name>webAppRootKey</param-name>
<param-value>myProject_name.root</param-value>
</context-param>
<param-name>webAppRootKey</param-name>
<param-value>myProject_name.root</param-value>
</context-param>
출처 : http://kekedie.tistory.com
0 Responses to [Spring Framework] Log4jConfigListener 컨텍스트 초기화 예외
Something to say?