spring 和struts整合过程遇到的一些错误
来源:互联网 发布:python的前景 编辑:程序博客网 时间:2024/06/10 07:41
Spring配置遇到的一些错误
错误:
>
java.lang.IllegalStateException: BeanFactory not initialized or already closed - call ‘refresh’ before accessing beans via the ApplicationContext
原因:spring初始化bean对象出错,id重复
IOException parsing XML document from ServletContext resource [/WEB-INF/applicationContext.xml];
原因:如果不特意指定参数名为contextConfigLoction的元素,那么spring的ContextLoderListener监听器就会在/WEB-INF/下去寻找并加载该目录下的名为applicationContext.xml这个文件
解决:在web.xml中添加标签并再次指定spring核心文件的位置。
<context-param> <param-name>contextConfigLocation</param-name> <param-value>classpath:applicationContext.xml</param-value> </context-param>
structs2配置
错误:
java.lang.ClassNotFoundException: org.apache.structs2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter
解决:2.1.3版本以前用org.apache.struts2.dispatcher.FilterDispatcher
2.1.3版本以后用org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter
spring和struts2整合
Action class [categoryAction] not found - action - file:/D:/myeclipse2014_workspace/.metadata/.me_tcat7/webapps/ssh/WEB-INF/classes/struts.xml:11:68
解决:导包 struts2-spring-plugin-2.3.4.jarThere is no Action mapped for namespace [/] and action name [listCategory] associated with context path [/ssh]. - [unknown location]
解决:配置文件和jar包问题,找不到actionmyeclipse中复制的web项目在部署到tomcat中时会部署之前的项目
解决:右键点击复制的web项目→properties→Myeclipse→project Facets→web→web context-root中输入复制后的项目名重新部署就好了
- spring 和struts整合过程遇到的一些错误
- 整合activiti过程中遇到的一些错误
- Spring的一些理解;struts整合spring
- struts和spring的整合
- struts和spring的整合!
- spring+hiberante整合单元测试遇到的错误
- spring+hiberante整合单元测试遇到的错误
- spring整合mybatis时遇到的错误
- Spring与Mybatis的整合过程中遇到的一些问题
- java web 中struts和spring的整合遇到的問題一
- 整合 Struts 和 Spring
- struts和spring整合
- 整合 Struts 和 Spring
- 整合 Struts 和 Spring
- Spring和Struts整合
- 整合spring 和struts
- spring和struts整合
- spring 和 struts 整合
- 虚拟机 网络模式简介 及桥接模式设置
- android app图标常用尺寸
- CHAR,VARCHAR,VARCHAR2,nvarchar,nvarchar2的用法和区别
- SpringMVC入门
- 搭建ELK(ElasticSearch+Logstash+Kibana)日志分析系统(八) elasticsearch配置外网访问及常见错误处理
- spring 和struts整合过程遇到的一些错误
- uva 10107 What is the Median?
- E
- KMP算法
- Spring-boot-CLI 安装与使用
- hdu 3706 Second My Problem First(单调队列)
- Eclipes下载并且导入GitHub中的maven项目
- 关于XML文档的xmlns、xmlns:xsi和xsi:schemaLocation
- 靠ta取胜?阿里云强势崛起冲击世界前三!