zoukankan      html  css  js  c++  java
  • [Java] SSH框架笔记_Struts2配置问题

    1、Unable to load bean: type: class:com.opensymphony.xwork2.ObjectFactory - bean - jar:file:/D:/Program%20Files/apache-tomcat-6.0.35/webapps/StrutsPro/WEB-INF/lib/struts2-core-2.3.4.jar!/struts-default.xml:29:72

    是由于tomcat本身的lib就有struts需要的包,而我们又自己添加了包而产生的冲突。

    2、只添加了5个包是不够的xwork-x.x.x.jar、commons-logging-x.x.x.jar、freemarker-x.x.x.jar、ognl-x.x.x.jar、struts2-core-x.x.x.jar)

    问题:严重: Dispatcher initialization failed
      java.lang.RuntimeException: java.lang.reflect.InvocationTargetException

    解决方法:添加javassist-x.x.x.ga.jar

    问题:警告: Could not create JarEntryRevision for [jar:file:/D:/Program%20Files/apache-tomcat-6.0.35/webapps/StrutsPro/WEB-INF/lib/struts2-core-2.3.4.jar]!
    java.lang.NoClassDefFoundError: org/apache/commons/io/FileUtils

    解决方法:添加commons-io-x.x.x.jar

    问题:严重: Exception starting filter struts2
    java.lang.NoClassDefFoundError: org/apache/commons/lang3/StringUtils

    解决方法:添加commons-langx.x.x.jar

    问题:严重: Dispatcher initialization failed
    Unable to load configuration. - bean - jar:file:/D:/Program%20Files/apache-tomcat-6.0.35/webapps/StrutsPro/WEB-INF/lib/struts2-core-2.3.4.jar!/struts-default.xml:51:178


    Caused by: java.lang.ClassNotFoundException: org.apache.commons.fileupload.RequestContext

    解决方法:添加commons-fileupload-x.x.x.jar

    --------------------------------------

    欢迎您,进入 我系程序猿 的cnBlog博客。

    你不能改变你的过去,但你可以让你的未来变得更美好。一旦时间浪费了,生命就浪费了。

    You cannot improve your past, but you can improve your future. Once time is wasted, life is wasted.

    --------------------------------------

    分享到QQ空间  

  • 相关阅读:
    03-数据结构(C语言版)
    01C语言基础(二)
    python杂项
    mmdetection源码阅读
    建立文件软连接
    python将test01文件夹中的文件剪切到test02文件夹中
    Probabilistic two-stage detection
    Activate-or-Not:learning-customized-activation
    CenterNet和CenterNet2笔记
    OpenCV视频检测人脸
  • 原文地址:https://www.cnblogs.com/jqmtony/p/3947834.html
Copyright © 2011-2022 走看看