[Java]Axis需要高版本的J2sdk编写者
日期
关键词
郑昀@ultrapower
2005-6-14
Java Web Service Axis Tomcat j2sdk
现象
按照 Install Axis 的详尽步骤依次安装了axis-bin-1_2、Tomcat 5.0,也按照要求复制相应的lib文件到Tomcat目录下。
但是,当重新启动Tomcat后,浏览http://localhost:8080/axis/,却得到了如下错误“org.apache.jasper.JasperException: Unable to compile class for JSP”,如下表所示:
错误页面提示:
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: Unable to compile class for JSP
No Java compiler was found to compile the generated source for the JSP.
This can usually be solved by copying manually $JAVA_HOME/lib/tools.jar from the JDK
to the common/lib directory of the Tomcat server, followed by a Tomcat restart.
If using an alternate Java compiler, please check its installation and access path.
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:83)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:315)
org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:406)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:463)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:442)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:430)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:511)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:274)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
note The full stack trace of the root cause is available in the Apache Tomcat/5.0.25 logs.
反复调整什么系统变量,都没有用。在GooglGroup上查询,也没有解决办法。
解决办法
原先安装的是j2sdk-1_4_1_02-windows-i586
最开始安装的是j2sdk-1_4_1_02-windows-i586.exe,看页面的提示,就把tools.jar复制到tomcat目录下,还是不行。
最终安装了j2sdk-1_4_2_08-windows-i586-p.exe:
把原来的j2sdk卸载,安装了最新的j2sdk-1_4_2_08-windows-i586-p.exe。并没有设置什么AXIS_HOME、AXIS_LIB等系统变量,只要把这个版本的D:\j2sdk1.4.2_08\lib\Tools.jar复制到D:\Tomcat 5.0\common\lib下,重启动Tomcat,就可以浏览Axis了。
并且以前发布的web service,也可以正常浏览了。
立此存照。
编写者
日期
关键词
郑昀@ultrapower
2005-6-14
Java Web Service Axis Tomcat j2sdk