Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
5.0.3
-
None
-
Tapestry, Spring Framework, Acegi Security
Description
In web.xml filters are applied in the order Acegi, Spring OpenSessionInView, Tapestry to make sure that all requests get processed by Acegi for security checking first, then OpenSessionInView makes sure there is an active Hibernate session.
When the request gets to Tapestry an NPE is thrown:
java.lang.NullPointerException
at $Request_11171fec8ae.getContextPath($Request_11171fec8ae.java)
at $Request_11171fec858.getContextPath($Request_11171fec858.java)
at org.apache.tapestry.internal.services.RequestRenderer.render(RequestRenderer.java:34)
at org.apache.tapestry.internal.services.RequestRenderer.render(RequestRenderer.java:24)
at $ObjectRenderer_11171fec8ad.render($ObjectRenderer_11171fec8ad.java)
at $ObjectRenderer_11171fec855.render($ObjectRenderer_11171fec855.java)
at org.apache.tapestry.corelib.components.RenderObject.beginRender(RenderObject.java:37)
at org.apache.tapestry.corelib.components.RenderObject.beginRender(RenderObject.java)
at org.apache.tapestry.internal.structure.ComponentPageElementImpl$10$1.run(ComponentPageElementImpl.java:345)
at org.apache.tapestry.internal.structure.ComponentPageElementImpl.invoke(ComponentPageElementImpl.java:932)
at org.apache.tapestry.internal.structure.ComponentPageElementImpl.access$100(ComponentPageElementImpl.java:69)
at org.apache.tapestry.internal.structure.ComponentPageElementImpl$10.render(ComponentPageElementImpl.java:349)
at org.apache.tapestry.internal.services.RenderQueueImpl.run(RenderQueueImpl.java:57)
at org.apache.tapestry.internal.services.PageMarkupRendererImpl.renderPageMarkup(PageMarkupRendererImpl.java:40)
at $PageMarkupRenderer_11171fec8a6.renderPageMarkup($PageMarkupRenderer_11171fec8a6.java)
at org.apache.tapestry.internal.services.PageResponseRendererImpl.renderPageResponse(PageResponseRendererImpl.java:45)
at $PageResponseRenderer_11171fec86d.renderPageResponse($PageResponseRenderer_11171fec86d.java)
at org.apache.tapestry.internal.services.DefaultRequestExceptionHandler.handleRequestException(DefaultRequestExceptionHandler.java:60)
at $RequestExceptionHandler_11171fec860.handleRequestException($RequestExceptionHandler_11171fec860.java)
at org.apache.tapestry.services.TapestryModule$3.service(TapestryModule.java:745)
at $RequestHandler_11171fec87f.service($RequestHandler_11171fec87f.java)
at org.apache.tapestry.internal.services.StaticFilesFilter.service(StaticFilesFilter.java:63)
at $RequestHandler_11171fec87f.service($RequestHandler_11171fec87f.java)
at org.apache.tapestry.internal.services.CheckForUpdatesFilter$2.invoke(CheckForUpdatesFilter.java:91)
at org.apache.tapestry.internal.services.CheckForUpdatesFilter$2.invoke(CheckForUpdatesFilter.java:82)
at org.apache.tapestry.ioc.internal.util.ConcurrentBarrier.withRead(ConcurrentBarrier.java:77)
at org.apache.tapestry.internal.services.CheckForUpdatesFilter.service(CheckForUpdatesFilter.java:104)
at $RequestHandler_11171fec87f.service($RequestHandler_11171fec87f.java)
at $RequestHandler_11171fec87b.service($RequestHandler_11171fec87b.java)
at org.apache.tapestry.services.TapestryModule$11.service(TapestryModule.java:1179)
at $HttpServletRequestHandler_11171fec87a.service($HttpServletRequestHandler_11171fec87a.java)
at org.apache.tapestry.TapestryFilter.doFilter(TapestryFilter.java:115)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1040)
at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:173)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:77)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1040)
at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:264)
at org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:107)
at org.acegisecurity.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:72)
at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
at org.acegisecurity.ui.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:110)
at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
at org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:178)
at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
at org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:229)
at org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:274)
at org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:148)
at org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:98)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1040)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:352)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:230)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:627)
at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:149)
at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:123)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:141)
at org.mortbay.jetty.Server.handle(Server.java:286)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:444)
at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:701)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:500)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:203)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:340)
at org.mortbay.jetty.nio.HttpChannelEndPoint.run(HttpChannelEndPoint.java:270)
at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:475)