19:24:26.662 [main] DEBUG org.springframework.core.io.support.PathMatchingResourcePatternResolver - Looking for matching resources in directory tree [C:\Depot\git\icm\dev\application\algorithm\target\classes]
19:24:26.663 [main] DEBUG org.springframework.core.io.support.PathMatchingResourcePatternResolver - Searching directory [C:\Depot\git\icm\dev\application\algorithm\target\classes] for files matching pattern [C:/Depot/git/icm/dev/application/algorithm/target/classes/appcxt-*.xml]
19:24:26.676 [main] DEBUG org.springframework.core.io.support.PathMatchingResourcePatternResolver - Resolved location pattern [classpath:appcxt-*.xml] to resources []
19:24:26.678 [main] INFO org.springframework.beans.factory.xmlXmlBeanDefinitionReader - Loaded 0 bean definitions from location patterntrace如上。
我的xml都在classpath的jar包中,但是spring无法找到jar包中xml文件。
查询了spring文档。
如果要搜索jar包中的xml则需要这样写xml路径:
classpath[color=red]*[/color]:appcxt-*.xml
本文详细解析了使用Spring框架时遇到的问题,即Spring无法在jar包中找到xml配置文件的情况,并提供了正确的路径配置解决方案。
2524

被折叠的 条评论
为什么被折叠?



