users@glassfish.java.net

webapp deploy fails with java.lang.NoClassDefFoundError: javax/servlet/http

From: <glassfish_at_javadesktop.org>
Date: Mon, 29 Oct 2007 08:30:38 PST

When deploying this simple (just has a index.jsp page) war built using maven into Glassfish v2 I get a deployment exception:

Caused by: java.lang.NoClassDefFoundError: javax/servlet/http/HttpServlet
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
        at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
        at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
        at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
        at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
        at java.security.AccessController.doPrivileged(Native Method)

I'm attaching the file war below. You will notice that there are no libraries in the WEB-INF/lib folder and yet I get this failure.
[Message sent by forum member 'r_sudh' (r_sudh)]

http://forums.java.net/jive/thread.jspa?messageID=242718