- android - 多次调用 OnPrimaryClipChangedListener
- android - 无法更新 RecyclerView 中的 TextView 字段
- android.database.CursorIndexOutOfBoundsException : Index 0 requested, 光标大小为 0
- android - 使用 AppCompat 时,我们是否需要明确指定其 UI 组件(Spinner、EditText)颜色
我正在尝试在统包 Linux tomcat6 设备上使用 axis 1.4。
简短的版本是假设它是问题的根源;在 debian 上设置 AXISCLASSPATH 的正确方法是什么?
长版本是:
axis.war 部署正确。我已将 AXIS_HOME 和 AXIS_LIB 添加到 etc/environment 中,如下所示:
CATALINA_HOME="/usr/share/tomcat6"
CATALINA_BASE="/var/lib/tomcat6"
CATALINA_OPTS="-server -Xms384M -Xmx512M -XX:MaxPermSize=256M"
JAVA_HOME="/usr/lib/jvm/java-6-sun-1.6.0.26"
AXIS_HOME="/var/lib/tomcat6/webapps/axis"
AXIS_LIB="/var/lib/tomcat6/webapps/axis/WEB-INF/lib"
并且所有回显都正确。 tomcat6 管理页面显示 axis 正在运行,/localhost/axis 加载正常,但 happyaxis 正在运行:
HTTP Status 500 -
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
org.apache.jasper.JasperException: An exception occurred processing JSP page /happyaxis.jsp at line 45
42: */ 43: Class classExists(String classname) { 44:
try { 45: return Class.forName(classname); 46: } catch (ClassNotFoundException e) { 47: return null; 48:
}Stacktrace: org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:521) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:412) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260) javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
root cause
javax.servlet.ServletException: java.lang.UnsupportedClassVersionError: com/ibm/wsdl/factory/WSDLFactoryImpl : Unsupported major.minor version 51.0 (unable to load class com.ibm.wsdl.factory.WSDLFactoryImpl) org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:865) org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:794) org.apache.jsp.happyaxis_jsp._jspService(happyaxis_jsp.java:808) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:388) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260) javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
root cause
java.lang.UnsupportedClassVersionError: com/ibm/wsdl/factory/WSDLFactoryImpl : Unsupported major.minor version 51.0 (unable to load class com.ibm.wsdl.factory.WSDLFactoryImpl) org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2822) org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1159) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1647) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1526) org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:128) org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:66) java.lang.Class.forName0(Native Method) java.lang.Class.forName(Class.java:169) org.apache.jsp.happyaxis_jsp.classExists(happyaxis_jsp.java:34) org.apache.jsp.happyaxis_jsp.probeClass(happyaxis_jsp.java:77) org.apache.jsp.happyaxis_jsp.needClass(happyaxis_jsp.java:151) org.apache.jsp.happyaxis_jsp._jspService(happyaxis_jsp.java:650) org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:388) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260) javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
我过去在 ubuntu 上使用过 axis,但在使用 openjdk 时遇到了问题。所以我尝试删除 openjdk 并安装 sun-java-6 并得到相同的错误。
根据我见过的所有文档,$AXISCLASSPATH 需要指向 axis/lib .jar 文件,这可能是问题所在,但 apache 文档非常旧:
Unix users have to do something similar. Below we have installed AXIS into /usr/axis and are using the bash shell. See your shell's documentation for differences. To make variables permeate you will need to add them to your shell's startup (dot) files. Again, see your shell's documentation.
set AXIS_HOME=/usr/axis
set AXIS_LIB=$AXIS_HOME/lib
set AXISCLASSPATH=$AXIS_LIB/axis.jar:$AXIS_LIB/commons-discovery.jar:
$AXIS_LIB/commons-logging.jar:$AXIS_LIB/jaxrpc.jar:$AXIS_LIB/saaj.jar:
$AXIS_LIB/log4j-1.2.8.jar:$AXIS_LIB/xml-apis.jar:$AXIS_LIB/xercesImpl.jar
export AXIS_HOME; export AXIS_LIB; export AXISCLASSPATH
当我部署时,xercesImpl.jar 不存在于 lib 目录中,而 log4-1.2.8.jar 只是 log4j.jar
我从文件系统中的其他位置复制了 xercesImpl,经过详尽的搜索后,我尝试从命令行、etc/environment、tomcat6.sh 和其他一些设置此变量,但都没有成功。
我发现能正确回显的唯一方法是使用命令行代码:
export AXISCLASSPATH:$AXIS_LIB/axis.jar;$AXIS_LIB/commons-discover.jar;$AXIS_LIB/commons-logging.jar;$AXIS_LIB/jaxrpc.jar;$AXIS_LIB/saaj.jar;$AXIS_LIB/log4j.jar
还是没有变化。作为黑暗中的一击,我将 wsdl4j.jar 从文件系统上的其他位置复制到/lib 并将其添加到上面的导出命令中,但仍然没有任何乐趣
最佳答案
“不支持的major.minor版本51.0”表示“JVM版本太低;51== Java7”。
史蒂夫
(10 年前编写 happyaxis.jsp)
关于linux - axis 1.4 linux求助-happyaxis不开心 AXISCLASSPATH全错了?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15573506/
我是一名优秀的程序员,十分优秀!