tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ghodmode <>
Subject Re: NoClassDefFoundError: javax/servlet/http/HttpServlet
Date Mon, 03 Sep 2007 21:38:28 GMT
On 9/4/07, Caldarale, Charles R <> wrote:
> ...

David D already pointed out the likely cause of the problem.
> - Chuck

Unfortunately, David's idea wasn't a solution for me.  There aren't any
files in my WEB-INF/lib directory.

I only created this HelloServlet to eliminate other possible causes of this
problem with more complex servlets.

One detail that I forgot to mention is that if I only add one web
application, it works fine.  There's only a problem when I add more than one
application to the webapps directory.  Because of this, it occurred to me
that I might somehow be causing a conflict with how I am putting the web
apps in there.  However, the problem even occurs when I have two identical
HelloServlet classes which differ only in the name of the subdirectory to
the webapps folder and the name of their class.

When I try to set this up, I stop Tomcat, build the directory, compile the
class (javac -cp
~/dev/tomcat/lib/servlet-api.jarmypackage/, and
start Tomcat again.  When I do this, one
always works and the others fail.

I'm not using WAR files.  I'm just putting all of the files in the necessary
locations already "exploded".  Is this significant?

Thank you,

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message