wtorek, 17 lutego 2009

tapestry 5 - run-jetty-run - NoClassDefFoundError

When I tried to run tapestry 5 tutorial application under Eclipse using run-jetty-run plugin I had following error:
Exception in thread "main" java.lang.NoClassDefFoundError:
javax/servlet/http/HttpServletRequest
at runjettyrun.Bootstrap.main(Bootstrap.java:60)

This is because of the version of run-jetty-run plugin I'm using doesn't have servlet-api jar included. There is a patchto fix this issue. In my case I haven't used the patch but I've added following dependecy to pom.xml:
<dependency>
   <groupId>jetty</groupId>
   <artifactId>servlet-api</artifactId>
   <version>2.5-6.0.2</version>
</dependency>

and now I works fine.

Brak komentarzy: