You have to add <dispatcher>ERROR</dispatcher> to your StripesFilter
mapping, similar to how it's shown in the DynamicMappingFilter javadocs.

http://stripes.sourceforge.net/docs/current/javadoc/net/sourceforge/stripes/controller/DynamicMappingFilter.html

-Ben

On Thu, Oct 1, 2009 at 1:08 AM, Geoff Shuetrim <ge...@galexy.net> wrote:

> I am using Stripes 1.5.1 and Tomcat 6.
>
> I am trying to use a stripes action to respond to requests that result in a
> 404 error.
>
> I have added:
>
>   <error-page>
>     <error-code>404</error-code>
>     <location>/errors/Error.action</location>
>   </error-page>
>
> to the web application's web.xml file.
>
> When I trigger a 404 error, the following log entry is generated and the
> web browser is sent to the default 404 error page.
>
> 01/10/2009 2:53:49 PM org.apache.catalina.core.ApplicationDispatcher invoke
> SEVERE: Servlet.service() for servlet StripesDispatcher threw exception
> java.lang.IllegalStateException: A request made it through to some part of
> Stripes without being wrapped in a StripesRequestWrapper. The StripesFilter
> is responsible for wrapping the request, so it is likely that either the
> StripesFilter is not deployed, or that its mappings do not include the
> DispatcherServlet _and_ *.jsp. Stripes does not require that the Stripes
> wrapper is the only request wrapper, or the outermost; only that it is
> present.
>     at
> net.sourceforge.stripes.controller.StripesRequestWrapper.findStripesWrapper(StripesRequestWrapper.java:81)
>     at
> net.sourceforge.stripes.controller.DefaultActionBeanPropertyBinder.bind(DefaultActionBeanPropertyBinder.java:207)
>     at
> net.sourceforge.stripes.controller.DispatcherHelper$3.intercept(DispatcherHelper.java:194)
>     at
> net.sourceforge.stripes.controller.ExecutionContext.proceed(ExecutionContext.java:158)
>     at
> net.sourceforge.stripes.controller.BeforeAfterMethodInterceptor.intercept(BeforeAfterMethodInterceptor.java:113)
>     at
> net.sourceforge.stripes.controller.ExecutionContext.proceed(ExecutionContext.java:155)
>     at
> net.sourceforge.stripes.controller.ExecutionContext.wrap(ExecutionContext.java:74)
>     at
> net.sourceforge.stripes.controller.DispatcherHelper.doBindingAndValidation(DispatcherHelper.java:190)
>     at
> net.sourceforge.stripes.controller.DispatcherServlet.doBindingAndValidation(DispatcherServlet.java:254)
>     at
> net.sourceforge.stripes.controller.DispatcherServlet.service(DispatcherServlet.java:148)
>     at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
>     at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>     at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>     at
> org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:646)
>     at
> org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:438)
>     at
> org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:374)
>     at
> org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:302)
>     at
> org.apache.catalina.core.StandardHostValve.custom(StandardHostValve.java:416)
>     at
> org.apache.catalina.core.StandardHostValve.status(StandardHostValve.java:343)
>     at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:144)
>     at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>     at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>     at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
>     at
> org.apache.coyote.ajp.AjpAprProcessor.process(AjpAprProcessor.java:427)
>     at
> org.apache.coyote.ajp.AjpAprProtocol$AjpConnectionHandler.process(AjpAprProtocol.java:384)
>     at
> org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1527)
>     at java.lang.Thread.run(Thread.java:619)
>
> Any ideas on how to make such requests for Stripes actions be wrapped
> properly?
>
> Thanks
>
> Geoff Shuetrim
>
>
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay
> ahead of the curve. Join us from November 9&#45;12, 2009. Register now&#33;
> http://p.sf.net/sfu/devconf
> _______________________________________________
> Stripes-users mailing list
> Stripes-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/stripes-users
>
>
------------------------------------------------------------------------------
Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9&#45;12, 2009. Register now&#33;
http://p.sf.net/sfu/devconf
_______________________________________________
Stripes-users mailing list
Stripes-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/stripes-users

Reply via email to