Paul,
If I try to inject the servlet request using:
@HttpContext HttpServletRequest r;
I get the following error:
2008-04-08 12:18:52.335::WARN: Error for /footballfixtures
java.lang.NoClassDefFoundError: javax/annotation/Resource
at
com.sun.ws.rest.spi.container.servlet.ServletContainer$1.getAnnotationCl
ass(ServletContainer.java:276)
at com.sun.ws.rest.spi.resource.Injectable.inject(Injectable.java:52)
at
com.sun.ws.rest.impl.application.WebApplicationImpl.injectResources(WebA
pplicationImpl.java:197)
at
com.sun.ws.rest.impl.application.WebApplicationImpl.injectResources(WebA
pplicationImpl.java:189)
at
com.sun.ws.rest.impl.application.WebApplicationContext.injectDependencie
s(WebApplicationContext.java:95)
at
com.sun.ws.rest.impl.resource.PerRequestProvider.getInstance(PerRequestP
rovider.java:70)
at
com.sun.ws.rest.impl.application.WebApplicationContext.getResource(WebAp
plicationContext.java:127)
at
com.sun.ws.rest.impl.uri.rules.ResourceClassRule.accept(ResourceClassRul
e.java:49)
at
com.sun.ws.rest.impl.uri.rules.RightHandPathRule.accept(RightHandPathRul
e.java:83)
at
com.sun.ws.rest.impl.uri.rules.RootResourceClassesRule.accept(RootResour
ceClassesRule.java:49)
at
com.sun.ws.rest.impl.application.WebApplicationImpl.handleRequest(WebApp
licationImpl.java:246)
at
com.sun.ws.rest.spi.container.servlet.ServletContainer.service(ServletCo
ntainer.java:123)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at
org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487)
at
org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:362)
at
org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
at
org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:726)
at
org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:324)
at
org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:505)
at
org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConne
ction.java:828)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:514)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:211)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380)
at
org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.jav
a:228)
at
org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.ja
va:450)
maybe I have some missing jar?
Jonathan
http://www.bbc.co.uk/
This e-mail (and any attachments) is confidential and may contain personal views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.