스프링 보안을 사용하고 있지만 어떤 이유로 내 web.xml이 내 applicationContext를 찾지 못합니다. .XML web.xml을java.io.FileNotFoundException : 클래스 경로 리소스 [conf/admin/applicationContext.xml]이 존재하지 않아 열 수 없습니다.
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>
classpath:conf/admin/applicationContext.xml
classpath:conf/admin/applicationContext-security.xml
</param-value>
</context-param>
<filter>
<filter-name>springSecurityFilterChain</filter-name>
<filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
</filter>
<filter-mapping>
<filter-name>springSecurityFilterChain</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
내 applicationContext.xml 내 web.xml에 같은 장소에서 MyProject를/conf의/관리/applicationContext.xml에 있지만 항상 예외가 발생합니다 :
14:18:07,793 ERROR [ContextLoader] Context initialization failed
org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML document from class path resource [conf/admin/applicationContext.xml]; nested exception is java.io.FileNotFoundException: class path resource [conf/admin/applicationContext.xml] cannot be opened because it does not exist
을
나는 WEB-INF 폴더 안에 넣는 것을 시도했다. (모든 Spring Security 튜토리얼은 myProject/dist/web/WEB-INF에 있지만, 새로 고치고 다시 빌드 할 프로젝트를 정리하면 삭제됩니다.
그래서 내가 뭘 잘못하고 있니? contextConfigLocation
또는 applicationContext.xml에 잘못된 경로를 잘못 넣었습니까?
@StudioWorks이 질문에 대한 답변이 있으면이 솔루션을 수락하십시오. –