zhyh1105 / run-jetty-run

Automatically exported from code.google.com/p/run-jetty-run
0 stars 0 forks source link

Need to add servlet-api-2.5-6.1.6.jar #3

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
When trying to use the plugin on my web app, I get the following error:

Exception in thread "main" java.lang.NoClassDefFoundError:
javax/servlet/http/HttpServletRequest
    at runjettyrun.Bootstrap.main(Bootstrap.java:60)

I was able to fix this by adding the servlet-api-2.5-6.1.6.jar to the
runtime classpath, but I think the plugin should already come this way. 
According to the Jetty docs, embedded Jetty should include this jar file. 
It is pointless to embed Jetty and then not include this jar, since web
apps can't run without it.

See for yourself:
http://docs.codehaus.org/display/JETTY/Embedding+Jetty#EmbeddingJetty-Settingupt
heclasspath

Original issue reported on code.google.com by dom...@gmail.com on 16 Jan 2008 at 8:06

GoogleCodeExporter commented 9 years ago
I don't know if they still do, but Sun used to restrict redistribution of its 
jars. Maybe that's why the jar wasn't 
included? Either way, the run-jetty-run "docs" should mention it.

Original comment by travis.m...@gmail.com on 24 Jan 2008 at 7:44

GoogleCodeExporter commented 9 years ago
I always have servlet.jar as part of the classpath of my projects, so I never 
have seen this problem. But I'll add 
the jar to the plugin with the next build.

Original comment by eelco.hi...@gmail.com on 3 Feb 2008 at 6:11

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Fixed for 1.0.1

Original comment by eelco.hi...@gmail.com on 3 Feb 2008 at 6:32

GoogleCodeExporter commented 9 years ago
Please re-open this ticket.

I just tried out 1.0.1, and this is still not fixed.  I see new jars for JSP 
support,
but I still do not see the Servlet API.

Original comment by dom...@gmail.com on 4 Feb 2008 at 10:05

GoogleCodeExporter commented 9 years ago
I agree with dombrd, it seems that the servlet-api-2.5-6.1.6.jar is not there.

I have a :

java.lang.NoSuchMethodError
javax.servlet.http.HttpServletRequest.setCharacterEncoding(String)

when I run my App from Eclipse, and the error disappear if I run mvn jetty:run.

Original comment by mar...@liber-mundi.org on 1 Apr 2008 at 12:41

GoogleCodeExporter commented 9 years ago
I just ran into this too.

Original comment by jkas...@gmail.com on 15 Jul 2008 at 5:59

GoogleCodeExporter commented 9 years ago
I just upgraded to ganymeade - and I'm trying to use this plugin.  My servlet 
starts
up just fine - but if I hit any url that is for a .jsp - it doesn't work - it 
just
says it can't find the file.

Should jsps be working in this version?

Thanks,

Mike

Original comment by mikeup...@gmail.com on 18 Jul 2008 at 1:24

GoogleCodeExporter commented 9 years ago
The servlet-api-2.5-6.1.6.jar file is bundled in 1.0.1, but is not actually put 
on
the classpath.  To achieve this, please apply the attached patch.  (I've also 
bumped
the version number to 1.0.2, hint, hint)

Cheers, Frank

Original comment by f...@vanlankvelt.net on 14 Jan 2009 at 4:22

Attachments: