maven中使用spring提示applicationContext.xml找不到
来源:互联网 发布:超次元矩阵 编辑:程序博客网 时间:2024/05/28 17:04
使用maven创建web工程,将Spring配置文件applicationContext.xml放在src/resource下,用eclipse编译时提示class path resource [applicationContext.xml] cannot be opened because it does not exist错误。但是用mvn clean package命令编译时成功的。web.xml配置的如下
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath:applicationContext.xml</param-value>
</context-param>
用google搜索一下(之前google用不了,用百度搜到蛋疼),发现是由于classpath不是指向resource路径,导致一直找不到文件。需要在classpath后面加个*,这样就解决问题了。
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath*:applicationContext.xml</param-value>
</context-param>
3 0
- maven中使用spring提示applicationContext.xml找不到
- 在Maven项目中加载spring中的bean的配置xml文件会提示找不到解决方法
- Spring,找不到applicationContext.xml的解决办法
- Spring程序找不到applicationContext.xml配置文件
- Spring程序找不到applicationContext.xml配置文件
- 找不到spring的applicationContext.xml异常
- Spring配置文件applicationContext.xml 找不到的问题
- spring中使用ApplicationContext
- 使用MyEclipse整合Struts+Spring+Hibernate时,在“applicationContext.xml”中提示class"org.apache.commons.dbcp.Basi
- Maven集成的Spring框架运行提示Failed to load ApplicationContext.xml
- Spring中操作applicationContext.xml
- spring applicationContext.xml 文件中<context:component-scan/>使用详解
- spring中遇到的applicationContext.xml (系统找不到指定的文件。)
- jar包中初始化Spring环境,报错找不到applicationContext.xml
- Spring配置文件applicationContext.xml在myEclipse工具中编写时如何显示标签提示
- hibernate3-maven-plugin 使用 spring applicationContext.xml中的sessionFactory配置(1)
- hibernate3-maven-plugin 使用 spring applicationContext.xml中的sessionFactory配置(2)
- Spring 中ApplicationContext使用 <02>
- 宏元编程——关系计算——not_equal
- Android基于BroadcastReceiver和Service、SoundPool开发的防过充助手app
- android 测试
- c++第二次实验1-2
- UIBezierPath+画板,签名档
- maven中使用spring提示applicationContext.xml找不到
- UVA10779 Collectors Problem(最大流)
- VS平台下 OpenGL glReadPixels、glDrawPixels、glCopyPixels函数
- 简单oracle存储过程测试
- 简单国际化操作(本地化)
- 北邮Google大牛本科研究生总结~
- Ubuntu下与github建立ssh连接
- JAVA练习---人民币小写转大写
- (三)镜像、容器 和 联合文件系统(Union File System)