最近,我开始在JBOss 4.0.5 JSP应用程序中遇到奇怪的行为. JSP编译在第一次(第二次,第三次,…)尝试失败,但有异常: 17:24:29,909 ERROR [[jsp]] Servlet.service() for servlet jsp threw exceptionjava.io.IOExcepti
17:24:29,909 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception java.io.IOException: tmpFile.renameTo(classFile) failed at org.apache.jasper.compiler.SmapUtil$SDEInstaller.install(SmapUtil.java:245) at org.apache.jasper.compiler.SmapUtil.installSmap(SmapUtil.java:164) at org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:429) at org.apache.jasper.compiler.Compiler.compile(Compiler.java:297) at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276) at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264) at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:305) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
在几次重试之后(少数是0到7),页面最终被编译并呈现OK.
平台是Windows 7-Pro 64位,Java版本是
c:\ATG\ATG2007.1>java -version java version "1.5.0_21" Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_21-b01) Java HotSpot(TM) Client VM (build 1.5.0_21-b01, mixed mode)
JBoss版本:
16:49:51,384 INFO [Server] Release ID: JBoss [Zion] 4.0.5.GA (build: CVSTag=Branch_4_0 date=200610162339)
Tomcat版本是5.5(JBoss附带的版本).
谢谢.
这与 Tomcat 5.5 bug 38713有关.似乎在Tomcat 5.5.25开始修复.