Daniel Gresh wrote:
Daniel Gresh wrote:
APliszka-Public wrote:
Google for "compilerSourceVM", and you should find examples of
enabling 1.5.
Andrew Pliszka
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Hi all, thanks for the fast replies.
I googled "compilerSourceVM" and came across this thread on the Java
forums:
http://forum.java.sun.com/thread.jspa?threadID=579806&messageID=2928513
I followed the instructions there. I removed jasper-compiler-jdt.jar
from my $CATALINA_HOME/common/lib directory. Then, I noticed my Ant
version was 1.5.4, so I downloaded Ant 1.7.0 instead, as 1.5.4 is not
compatible with JDK1.5. Next, I added ant.jar to the
$CATALINA_HOME/common/lib directory. Then, I edited my web.xml file
in the $CATALINA_HOME/conf directory according to the thread on the
Java forums and the Jasper how-to. Finally, I restarted Tomcat.
I am still getting a problem however, and I believe this deals with
ant. When I try to compile code -- ANY code from ANY JDK -- even
something like:
<%
String s;
%>
I get this error:
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
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:565)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
*root cause*
java.lang.NullPointerException
org.apache.jasper.compiler.AntCompiler.generateClass(AntCompiler.java:159)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:288)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
I haven't removed the older version of Ant (Ant 1.5.4). Could this be
causing the problem? Or is there something else I am missing?
Also, I accidentally clicked refresh on my browser after getting this
error, and the page loaded. I hit refresh a few more times and it
loaded. Then, it gave me the error again, and repeated. I doubt it's
pertinent, but who knows.
Thanks,
Dan
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Oh I should have mentioned that when I type ant -version I get the error:
Exception in thread "main" java.lang.NoClassDefFoundError:
org/apache/tools/ant/Main
Dan
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
List,
I solved my problem with getting ant -version to work. The older version
of Ant was apparently causing problems, but I can't remove it. So, I set
the newer version of Ant at the beginning of PATH, so when I type ant
-version, it will be referenced first, and it will give me the correct
version (1.7.0). However, I am still getting a problem when I try to
compile. I've searched Google for help, but I haven't managed to find any.
The error message has changed slightly from the last one, so here it is:
HTTP Status 500 -
------------------------------------------------------------------------
*type* Exception report
*message*
*description* _The server encountered an internal error () that
prevented it from fulfilling this request._
*exception*
javax.servlet.ServletException: org/apache/tools/ant/launch/AntMain
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:249)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
*root cause*
java.lang.NoClassDefFoundError: org/apache/tools/ant/launch/AntMain
java.lang.ClassLoader.defineClass1(Native Method)
java.lang.ClassLoader.defineClass(ClassLoader.java:620)
java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
java.net.URLClassLoader.access$100(URLClassLoader.java:56)
java.net.URLClassLoader$1.run(URLClassLoader.java:195)
java.security.AccessController.doPrivileged(Native Method)
java.net.URLClassLoader.findClass(URLClassLoader.java:188)
java.lang.ClassLoader.loadClass(ClassLoader.java:306)
java.lang.ClassLoader.loadClass(ClassLoader.java:251)
java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
org.apache.tools.ant.Project.initProperties(Project.java:308)
org.apache.tools.ant.Project.init(Project.java:295)
org.apache.jasper.compiler.AntCompiler.getProject(AntCompiler.java:74)
org.apache.jasper.compiler.AntCompiler.generateClass(AntCompiler.java:129)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:288)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
Why can it not find AntMain? Where would that be located so I can instruct
Tomcat to find this?
Any help would be appreciated, and if there's anything else I can do that might
help, please let me know.
Thanks,
Dan
---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]