Bug 26316 - Jasper refuses to compile JSP pages
Summary: Jasper refuses to compile JSP pages
Status: RESOLVED WONTFIX
Alias: None
Product: Tomcat 5
Classification: Unclassified
Component: Jasper (show other bugs)
Version: 5.0.16
Hardware: PC All
: P3 normal with 1 vote (vote)
Target Milestone: ---
Assignee: Tomcat Developers Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-01-21 18:12 UTC by Ilia Sharonov
Modified: 2005-03-20 17:06 UTC (History)
0 users



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ilia Sharonov 2004-01-21 18:12:40 UTC
Jasper refuses to compile JSP pages. JAVA_HOME parameter is set correctly 
(Tomcat indicates it when started using startup.bat from the installation). 
tools.jar is copied to common\lib.
Stack trace:

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:127)
	org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:
351)
	org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:415)
	org.apache.jasper.compiler.Compiler.compile(Compiler.java:458)
	org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
	org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:
552)
	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:
291)
	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
Comment 1 Remy Maucherat 2004-01-21 21:29:17 UTC
If the problem is about compiling any JSP pages, I have yet to see a case where
this isn't caused by javac not being found, for whatever reason. The report
isn't very clear overall. Please post on tomcat-user.
Comment 2 Jim Weir 2004-03-05 21:14:52 UTC
Tomcat is producing this misleading message when it encounters any compilation 
errors while compiling any JSP file.  It stuffs those errors messages in the 
server log.  Perhaps you could change the error output to something less 
confusing because it is NOT in fact having trouble finding the compiler.

-JW
Comment 3 Remy Maucherat 2004-03-05 22:24:22 UTC
This can occur only if somehow the output capture fails (which it never does
with the default configuration). I consider this good enough, please do not
reopen this report.