Dispatcher initialization failed问题的解决方法

严重: Dispatcher initialization failed java.lang.RuntimeException: java.lang.reflect.InvocationTargetException处理方法:1、核对lib包    commons-fileupload-1.2.1.jar,

                      commons-io-1.3.2.jar

                      commons-logging-1.0.4.jar

                      freemarker-2.3.16.jar

                      ognl-3.0.jar

                     struts2-core-2.2.1.jar

                     xwork-core-2.2.1.jar

注意2.1以前是没有commons-fileupload-1.2.1.jar。

2、如果struts2版本是2.1以前web.xml配置过滤器的时候应该是这样:<filter-class>org.apache.struts2.dispatcher.FilterDispatcher </filter-class>         

     如果struts2 版本是2.1以上web.xml配置 <filter-class>org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter</filter-class>

3、 在使用struts-2.2.1时,需要引入javassist-3.7.ga.jar,而这个在struts-2.2.1\lib下是没有的,需要在struts-2.2.1\apps\struts2-blank-2.2.1.war下的lib中找。

4、使用struts2.3以上的版本需要依赖更多的包,具体看tomcat启动出错情况

转载于:https://my.oschina.net/u/815213/blog/93371

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值