Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Gyrex » Problem with JaxRsApplication after update to 1.2
Problem with JaxRsApplication after update to 1.2 [message #1065525] Wed, 26 June 2013 06:35 Go to next message
thomas huster is currently offline thomas huster
Messages: 4
Registered: June 2012
Junior Member
Since I updated to Gyrex 1.2, Jetty 9.0.3 and Jersey 1.17.0 my REST Services have a problem. The following Exception occures.

java.lang.NullPointerException
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:538)
at com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:716)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:681)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:452)
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:184)
at org.eclipse.gyrex.http.jetty.internal.app.ApplicationDelegateHandler.doHandle(ApplicationDelegateHandler.java:92)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:211)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1083)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:379)

I debugged into the startup of the JaxRsApplication and it looks like the JaxRsApplication#doInit is called, and a new ServletContainer is registered. But the ServletContainer#init method is never called.

Should I overwrite the JaxRsApplication#doInit method and call ServletContainer#init there? Or is that the responsibility of a module I missed updating the target? Or ???

Thanks,
Thomas
Re: Problem with JaxRsApplication after update to 1.2 [message #1065764 is a reply to message #1065525] Thu, 27 June 2013 08:27 Go to previous messageGo to next message
Gunnar Wagenknecht is currently offline Gunnar Wagenknecht
Messages: 446
Registered: July 2009
Senior Member
Hi Thomas,

It does ring a bell. We discovered a similar issue a while back when upgrading from Jetty 9.0.0 to 9.0.3. Something changed in the servlet initialization. I believe that we fixed this one. But can you please open a bug Report for us to investigate? Thanks!

Meanwhile, the workaround you proposed should work in case it's the same problem.

-Gunnar
Re: Problem with JaxRsApplication after update to 1.2 [message #1065850 is a reply to message #1065764] Thu, 27 June 2013 15:16 Go to previous messageGo to next message
thomas huster is currently offline thomas huster
Messages: 4
Registered: June 2012
Junior Member
Hi Gunnar,

thx for the quick reply. I opened https://bugs.eclipse.org/bugs/show_bug.cgi?id=411823.

[Updated on: Thu, 27 June 2013 15:35]

Report message to a moderator

Re: Problem with JaxRsApplication after update to 1.2 [message #1067652 is a reply to message #1065850] Tue, 09 July 2013 15:57 Go to previous message
Gunnar Wagenknecht is currently offline Gunnar Wagenknecht
Messages: 446
Registered: July 2009
Senior Member
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta http-equiv="Content-Style-Type" content="text/css">
<title></title>
<meta name="Generator" content="Cocoa HTML Writer">
<meta name="CocoaVersion" content="1187.39">
<style type="text/css">
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 15.0px; font: 12.0px Helvetica}
p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 15.0px; font: 12.0px Helvetica; min-height: 14.0px}
p.p3 {margin: 0.0px 0.0px 0.0px 12.0px; line-height: 14.0px; font: 12.0px Helvetica; color: #011892}
p.p4 {margin: 0.0px 0.0px 0.0px 12.0px; line-height: 14.0px; font: 12.0px Helvetica; color: #011892; min-height: 14.0px}
p.p5 {margin: 0.0px 0.0px 0.0px 0.0px; line-height: 14.0px; font: 12.0px Helvetica; min-height: 14.0px}
p.p6 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica}
p.p7 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; min-height: 14.0px}
p.p8 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; color: #929292}
</style>
</head>
<body>
<p class="p1">On 2013-06-27 19:16:17 +0000, thomas huster said:</p>
<p class="p2"><br></p>
<p class="p3">Hi Gunnar,</p>
<p class="p4"><br></p>
<p class="p3">thx for the quick reply. I opened https://bugs.eclipse.org/bugs/show_bug.cgi?id=411823.</p>
<p class="p5"><br></p>
<p class="p6">I published a maintenance build with Jetty 9.0.4:</p>
<p class="p6"><a href="http://download.eclipse.org/gyrex/1.2/maintenance/">http://download.eclipse.org/gyrex/1.2/maintenance/</a></p>
<p class="p7"><br></p>
<p class="p6">-Gunnar</p>
<p class="p7"><br></p>
<p class="p8">--<span class="Apple-converted-space"> </span></p>
<p class="p8">Gunnar Wagenknecht</p>
<p class="p8">gunnar@xxxxxxxx</p>
</body>
</html>
Previous Topic:How to deploy a bundle in Gyrex
Next Topic:Where to find docs on multi-tenancy support?
Goto Forum:
  


Current Time: Thu Apr 17 23:40:32 EDT 2014

Powered by FUDForum. Page generated in 0.02150 seconds