Forwarding to a jsp that uses stripes taglib from a filter

View: New views
9 Messages — Rating Filter:   Alert me  

Forwarding to a jsp that uses stripes taglib from a filter

by Farouk Alhassan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
I have an intercepting filter that rewrites a url and forwards to the url (URLrewriter http://tuckey.org/urlrewrite/ )
 wrk lik
/contact will be retwritten as /contacts.jsp and forwarded to the jsp. However the jsp throws a very nice NPE. dont know. a little dig into the stripes
code reveals the execption on this line

        // Assuming that the layout definition page is always included, the following line gets
        // the name of the page the tag is sitting on, as per Servlet 2.4 spec, page 65.
        String name = (String) getPageContext().getRequest()
                .getAttribute('javax.servlet.include.servlet_path');

what can i do, to get round it. I have attached the stack trace

> -------------------------------------------------------------------------
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> _______________________________________________
> Stripes-users mailing list
> Stripes-users@...
> https://lists.sourceforge.net/lists/listinfo/stripes-users


Get Started!
Jul 2, 2008 8:04:53 AM org.apache.catalina.core.ApplicationDispatcher invoke
SEVERE: Servlet.service() for servlet jsp threw exception
java.lang.NullPointerException
        at net.sourceforge.stripes.tag.layout.LayoutDefinitionTag.doStartTag(LayoutDefinitionTag.java:72)
        at org.apache.jsp.pb.contacts_005ftmpl_jsp._jspx_meth_s_005flayout_002ddefinition_005f0(contacts_005ftmpl_jsp.java:87)
        at org.apache.jsp.pb.contacts_005ftmpl_jsp._jspService(contacts_005ftmpl_jsp.java:64)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        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:654)
        at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
        at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
        at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:968)
        at org.apache.jasper.runtime.PageContextImpl.doInclude(PageContextImpl.java:638)
        at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:632)
        at net.sourceforge.stripes.tag.layout.LayoutRenderTag.doEndTag(LayoutRenderTag.java:113)
        at org.apache.jsp.pb.contacts_jsp._jspx_meth_s_005flayout_002drender_005f0(contacts_jsp.java:103)
        at org.apache.jsp.pb.contacts_jsp._jspService(contacts_jsp.java:59)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at net.sourceforge.stripes.controller.StripesFilter.doFilter(StripesFilter.java:210)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
        at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:445)
        at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:379)
        at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:292)
        at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195)
        at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159)
        at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
        at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
        at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
        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:263)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:584)
        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
        at java.lang.Thread.run(Thread.java:619)
Jul 2, 2008 8:04:53 AM org.apache.catalina.core.ApplicationDispatcher invoke
SEVERE: Servlet.service() for servlet jsp threw exception
java.lang.NullPointerException
        at net.sourceforge.stripes.tag.layout.LayoutDefinitionTag.doStartTag(LayoutDefinitionTag.java:72)
        at org.apache.jsp.pb.contacts_005ftmpl_jsp._jspx_meth_s_005flayout_002ddefinition_005f0(contacts_005ftmpl_jsp.java:87)
        at org.apache.jsp.pb.contacts_005ftmpl_jsp._jspService(contacts_005ftmpl_jsp.java:64)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        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:654)
        at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
        at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
        at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:968)
        at org.apache.jasper.runtime.PageContextImpl.doInclude(PageContextImpl.java:638)
        at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:632)
        at net.sourceforge.stripes.tag.layout.LayoutRenderTag.doEndTag(LayoutRenderTag.java:113)
        at org.apache.jsp.pb.contacts_jsp._jspx_meth_s_005flayout_002drender_005f0(contacts_jsp.java:103)
        at org.apache.jsp.pb.contacts_jsp._jspService(contacts_jsp.java:59)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at net.sourceforge.stripes.controller.StripesFilter.doFilter(StripesFilter.java:210)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
        at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:445)
        at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:379)
        at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:292)
        at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195)
        at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159)
        at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
        at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
        at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
        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:263)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:584)
        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
        at java.lang.Thread.run(Thread.java:619)
Jul 2, 2008 8:04:53 AM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet default threw exception
java.lang.NullPointerException
        at net.sourceforge.stripes.tag.layout.LayoutDefinitionTag.doStartTag(LayoutDefinitionTag.java:72)
        at org.apache.jsp.pb.contacts_005ftmpl_jsp._jspx_meth_s_005flayout_002ddefinition_005f0(contacts_005ftmpl_jsp.java:87)
        at org.apache.jsp.pb.contacts_005ftmpl_jsp._jspService(contacts_005ftmpl_jsp.java:64)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        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:654)
        at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:557)
        at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:481)
        at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:968)
        at org.apache.jasper.runtime.PageContextImpl.doInclude(PageContextImpl.java:638)
        at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:632)
        at net.sourceforge.stripes.tag.layout.LayoutRenderTag.doEndTag(LayoutRenderTag.java:113)
        at org.apache.jsp.pb.contacts_jsp._jspx_meth_s_005flayout_002drender_005f0(contacts_jsp.java:103)
        at org.apache.jsp.pb.contacts_jsp._jspService(contacts_jsp.java:59)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:393)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at net.sourceforge.stripes.controller.StripesFilter.doFilter(StripesFilter.java:210)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
        at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:445)
        at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:379)
        at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:292)
        at org.tuckey.web.filters.urlrewrite.NormalRewrittenUrl.doRewrite(NormalRewrittenUrl.java:195)
        at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:159)
        at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
        at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
        at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:417)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
        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:263)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:584)
        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
        at java.lang.Thread.run(Thread.java:619)

-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Stripes-users mailing list
Stripes-users@...
https://lists.sourceforge.net/lists/listinfo/stripes-users

Re: Forwarding to a jsp that uses stripes taglib from a filter

by Farouk Alhassan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
Hi guys, can someone help me here as i am stack.. a further debugging shows that  is definetily null. This may also be due to the fact the there is
confusion on the value returned by the

String name = (String) getPageContext().getRequest() .getAttribute('javax.servlet.include.servlet_path'); depending on whether its a include or a forward

http://www.caucho.com/resin-3.0/webapp/faq.xtp


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 08:07:03 +0100
Subject: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

I have an intercepting filter that rewrites a url and forwards to the url (URLrewriter http://tuckey.org/urlrewrite/ )
 wrk lik
/contact will be retwritten as /contacts.jsp and forwarded to the jsp. However the jsp throws a very nice NPE. dont know. a little dig into the stripes
code reveals the execption on this line

        // Assuming that the layout definition page is always included, the following line gets
        // the name of the page the tag is sitting on, as per Servlet 2.4 spec, page 65.
        String name = (String) getPageContext().getRequest()
                .getAttribute('javax.servlet.include.servlet_path');

what can i do, to get round it. I have attached the stack trace

> -------------------------------------------------------------------------
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> _______________________________________________
> Stripes-users mailing list
> Stripes-users@...
> https://lists.sourceforge.net/lists/listinfo/stripes-users


Get Started!


Get Hotmail on your Mobile! Try it Now!
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Stripes-users mailing list
Stripes-users@...
https://lists.sourceforge.net/lists/listinfo/stripes-users

Re: Forwarding to a jsp that uses stripes taglib from a filter

by Tim Fennell-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Do you have the URLRewrite filter mapped only to the REQUEST dispatcher, or does it also kick in on INCLUDEs?  It sounds to me like the Stripes code is expected to only ever be called through an include, and in this case is not because something is intercepting in the middle and doing something else.  Is that the case?  And if so, is there any need to have the URLRewrite work on anything except requests coming in from outside the container?

-t

On Jul 2, 2008, at 1:41 PM, Farouk Alhassan wrote:

Hi guys, can someone help me here as i am stack.. a further debugging shows that  is definetily null. This may also be due to the fact the there is
confusion on the value returned by the

String name = (String) getPageContext().getRequest() .getAttribute('javax.servlet.include.servlet_path'); depending on whether its a include or a forward

http://www.caucho.com/resin-3.0/webapp/faq.xtp


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 08:07:03 +0100
Subject: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

I have an intercepting filter that rewrites a url and forwards to the url (URLrewriter http://tuckey.org/urlrewrite/ )
 wrk lik
/contact will be retwritten as /contacts.jsp and forwarded to the jsp. However the jsp throws a very nice NPE. dont know. a little dig into the stripes
code reveals the execption on this line

        // Assuming that the layout definition page is always included, the following line gets
        // the name of the page the tag is sitting on, as per Servlet 2.4 spec, page 65.
        String name = (String) getPageContext().getRequest()
                .getAttribute('javax.servlet.include.servlet_path');

what can i do, to get round it. I have attached the stack trace

> -------------------------------------------------------------------------
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> _______________________________________________
> Stripes-users mailing list
> Stripes-users@...
> https://lists.sourceforge.net/lists/listinfo/stripes-users


Get Started!


Get Hotmail on your Mobile! Try it Now!
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08_______________________________________________
Stripes-users mailing list
https://lists.sourceforge.net/lists/listinfo/stripes-users


-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Stripes-users mailing list
Stripes-users@...
https://lists.sourceforge.net/lists/listinfo/stripes-users

Re: Forwarding to a jsp that uses stripes taglib from a filter

by Farouk Alhassan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
a short section of my web.xml. the urlRewriter creates the name of the jsp file requested and forwards to it. Stripes intercepts the forward to do instantiation before jsp is written

  <filter-mapping>   
   <filter-name>UrlRewriteFilter</filter-name>
   <url-pattern>/*</url-pattern>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <url-pattern>/*</url-pattern>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <servlet-name>StripesDispatcher</servlet-name>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>


From: tfenne@...
Date: Wed, 2 Jul 2008 13:48:02 -0400
To: stripes-users@...
Subject: Re: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

Do you have the URLRewrite filter mapped only to the REQUEST dispatcher, or does it also kick in on INCLUDEs?  It sounds to me like the Stripes code is expected to only ever be called through an include, and in this case is not because something is intercepting in the middle and doing something else.  Is that the case?  And if so, is there any need to have the URLRewrite work on anything except requests coming in from outside the container?

-t

On Jul 2, 2008, at 1:41 PM, Farouk Alhassan wrote:

Hi guys, can someone help me here as i am stack.. a further debugging shows that  is definetily null. This may also be due to the fact the there is
confusion on the value returned by the

String name = (String) getPageContext().getRequest() .getAttribute('javax.servlet.include.servlet_path'); depending on whether its a include or a forward

http://www.caucho.com/resin-3.0/webapp/faq.xtp


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 08:07:03 +0100
Subject: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

I have an intercepting filter that rewrites a url and forwards to the url (URLrewriter http://tuckey.org/urlrewrite/ )
 wrk lik
/contact will be retwritten as /contacts.jsp and forwarded to the jsp. However the jsp throws a very nice NPE. dont know. a little dig into the stripes
code reveals the execption on this line

        // Assuming that the layout definition page is always included, the following line gets
        // the name of the page the tag is sitting on, as per Servlet 2.4 spec, page 65.
        String name = (String) getPageContext().getRequest()
                .getAttribute('javax.servlet.include.servlet_path');

what can i do, to get round it. I have attached the stack trace

> -------------------------------------------------------------------------
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> _______________________________________________
> Stripes-users mailing list
> Stripes-users@...
> https://lists.sourceforge.net/lists/listinfo/stripes-users


Get Started!


Get Hotmail on your Mobile! Try it Now!
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08_______________________________________________
Stripes-users mailing list
https://lists.sourceforge.net/lists/listinfo/stripes-users



Find out how to make Messenger your very own TV! Try it Now!
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Stripes-users mailing list
Stripes-users@...
https://lists.sourceforge.net/lists/listinfo/stripes-users

Re: Forwarding to a jsp that uses stripes taglib from a filter(Its a bug)

by Farouk Alhassan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
My reading of the servlet spec shows that, using getAttribute('javax.servlet.include.servlet_path')-which is the only method used by net.sourceforge.stripes.tag.layout.LayoutDefinitionTag.doStart() -will work only if the include was used. since you should be
able to forward to the jsp page before that page invokes the layout-definition using include, the above method will have a wrong value since the parameter will not be there. at this point, it will be under getAttribute("javax.servlet.forward.servlet_path"); I therefore think stripes should consider this as well since the relegation of the control to the jsp can come from anywhere.

I dont know how to fix this though


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 19:19:18 +0100
Subject: Re: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

a short section of my web.xml. the urlRewriter creates the name of the jsp file requested and forwards to it. Stripes intercepts the forward to do instantiation before jsp is written

  <filter-mapping>   
   <filter-name>UrlRewriteFilter</filter-name>
   <url-pattern>/*</url-pattern>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <url-pattern>/*</url-pattern>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <servlet-name>StripesDispatcher</servlet-name>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>


From: tfenne@...
Date: Wed, 2 Jul 2008 13:48:02 -0400
To: stripes-users@...
Subject: Re: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

Do you have the URLRewrite filter mapped only to the REQUEST dispatcher, or does it also kick in on INCLUDEs?  It sounds to me like the Stripes code is expected to only ever be called through an include, and in this case is not because something is intercepting in the middle and doing something else.  Is that the case?  And if so, is there any need to have the URLRewrite work on anything except requests coming in from outside the container?

-t

On Jul 2, 2008, at 1:41 PM, Farouk Alhassan wrote:

Hi guys, can someone help me here as i am stack.. a further debugging shows that  is definetily null. This may also be due to the fact the there is
confusion on the value returned by the

String name = (String) getPageContext().getRequest() .getAttribute('javax.servlet.include.servlet_path'); depending on whether its a include or a forward

http://www.caucho.com/resin-3.0/webapp/faq.xtp


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 08:07:03 +0100
Subject: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

I have an intercepting filter that rewrites a url and forwards to the url (URLrewriter http://tuckey.org/urlrewrite/ )
 wrk lik
/contact will be retwritten as /contacts.jsp and forwarded to the jsp. However the jsp throws a very nice NPE. dont know. a little dig into the stripes
code reveals the execption on this line

        // Assuming that the layout definition page is always included, the following line gets
        // the name of the page the tag is sitting on, as per Servlet 2.4 spec, page 65.
        String name = (String) getPageContext().getRequest()
                .getAttribute('javax.servlet.include.servlet_path');

what can i do, to get round it. I have attached the stack trace

> -------------------------------------------------------------------------
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> _______________________________________________
> Stripes-users mailing list
> Stripes-users@...
> https://lists.sourceforge.net/lists/listinfo/stripes-users


Get Started!


Get Hotmail on your Mobile! Try it Now!
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08_______________________________________________
Stripes-users mailing list
https://lists.sourceforge.net/lists/listinfo/stripes-users



Find out how to make Messenger your very own TV! Try it Now!


Win £3000 to spend on whatever you want at Uni! Click here to WIN!
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Stripes-users mailing list
Stripes-users@...
https://lists.sourceforge.net/lists/listinfo/stripes-users

Re: Forwarding to a jsp that uses stripes taglib from a filter(Its a bug)

by Tim Fennell-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

The code that you have found comes from the LayoutDefinitionTag.  This tag should only ever occur on the page that defines the common layout (not on pages using that layout).  Because of this, certain assumptions are made:

1) Layout JSPs (those using s:layout-definition) are only ever executed by Stripes, and in fact by the layout-render tag.  You should not be forwarding to those yourself

2) The only way the s:layout-render tag ever executes the layout is via an INCLUDE

3) Therefore, when used properly, the call to find the include_path should work just fine

I'm not sure exactly what you're doing differently that is causing this problem.  Can you perhaps show us the JSP that is invoking the layout? 

-t

On Jul 2, 2008, at 5:42 PM, Farouk Alhassan wrote:

My reading of the servlet spec shows that, using getAttribute('javax.servlet.include.servlet_path')-which is the only method used by net.sourceforge.stripes.tag.layout.LayoutDefinitionTag.doStart() -will work only if the include was used. since you should be
able to forward to the jsp page before that page invokes the layout-definition using include, the above method will have a wrong value since the parameter will not be there. at this point, it will be under getAttribute("javax.servlet.forward.servlet_path"); I therefore think stripes should consider this as well since the relegation of the control to the jsp can come from anywhere.

I dont know how to fix this though


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 19:19:18 +0100
Subject: Re: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

a short section of my web.xml. the urlRewriter creates the name of the jsp file requested and forwards to it. Stripes intercepts the forward to do instantiation before jsp is written

  <filter-mapping>   
   <filter-name>UrlRewriteFilter</filter-name>
   <url-pattern>/*</url-pattern>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <url-pattern>/*</url-pattern>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <servlet-name>StripesDispatcher</servlet-name>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>


From: tfenne@...
Date: Wed, 2 Jul 2008 13:48:02 -0400
To: stripes-users@...
Subject: Re: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

Do you have the URLRewrite filter mapped only to the REQUEST dispatcher, or does it also kick in on INCLUDEs?  It sounds to me like the Stripes code is expected to only ever be called through an include, and in this case is not because something is intercepting in the middle and doing something else.  Is that the case?  And if so, is there any need to have the URLRewrite work on anything except requests coming in from outside the container?

-t

On Jul 2, 2008, at 1:41 PM, Farouk Alhassan wrote:

Hi guys, can someone help me here as i am stack.. a further debugging shows that  is definetily null. This may also be due to the fact the there is
confusion on the value returned by the

String name = (String) getPageContext().getRequest() .getAttribute('javax.servlet.include.servlet_path'); depending on whether its a include or a forward

http://www.caucho.com/resin-3.0/webapp/faq.xtp


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 08:07:03 +0100
Subject: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

I have an intercepting filter that rewrites a url and forwards to the url (URLrewriter http://tuckey.org/urlrewrite/ )
 wrk lik
/contact will be retwritten as /contacts.jsp and forwarded to the jsp. However the jsp throws a very nice NPE. dont know. a little dig into the stripes
code reveals the execption on this line

        // Assuming that the layout definition page is always included, the following line gets
        // the name of the page the tag is sitting on, as per Servlet 2.4 spec, page 65.
        String name = (String) getPageContext().getRequest()
                .getAttribute('javax.servlet.include.servlet_path');

what can i do, to get round it. I have attached the stack trace

> -------------------------------------------------------------------------
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> _______________________________________________
> Stripes-users mailing list
> Stripes-users@...
> https://lists.sourceforge.net/lists/listinfo/stripes-users


Get Started!


Get Hotmail on your Mobile! Try it Now!
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
Stripes-users mailing list



Find out how to make Messenger your very own TV! Try it Now!


Win £3000 to spend on whatever you want at Uni! Click here to WIN!
-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
Stripes-users mailing list


-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Stripes-users mailing list
Stripes-users@...
https://lists.sourceforge.net/lists/listinfo/stripes-users

Re: Forwarding to a jsp that uses stripes taglib from a filter(Its a bug)

by Farouk Alhassan :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Some parts of this message have been removed. Learn more about Nabble's security policy.
Sorry, it was overnight here in Uk, so I was asleep when u replied. sorry for the delay. Right i will show all four pages involved in this process

1. the rewrite rule is this

    <rule>
        <from>^/$</from>
        <to>/pb/home.jsp</to>
    </rule>

    <rule match-type="wildcard">
        <from>/*</from>
        <to>/pb/$1.jsp</to>
    </rule>
   
    <rule match-type="wildcard">
        <from>/do/lk/*</from>
        <to>/action/$1.action</to>
    </rule>
the second rule is what am intrested in most

2. web.xml

  <filter-mapping>   
   <filter-name>UrlRewriteFilter</filter-name>
   <url-pattern>/*</url-pattern>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <url-pattern>/*</url-pattern>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>INCLUDE</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <servlet-name>StripesDispatcher</servlet-name>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
    <dispatcher>INCLUDE</dispatcher>
  </filter-mapping>

thought only the filter mappings are important

3.contacts.jsp

<%@ taglib prefix="s" uri="http://stripes.sourceforge.net/stripes.tld" %>
<s:layout-render name="contacts_tmpl.jsp" title="Contact Us">
 
</s:layout-render>

4. contacts_tmpl.jsp


<%@ taglib prefix="d" uri="http://stripes.sourceforge.net/stripes-dynattr.tld" %>
<%@ taglib prefix="s" uri="http://stripes.sourceforge.net/stripes.tld" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>

<s:layout-definition>
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html>
    <head>
      <title>Our Promises</title>
      <link href="../css/style.css" rel="stylesheet" type="text/css" />
      <link href="../css/layout.css" rel="stylesheet" type="text/css" />
      <script src="../js_lib/rollover.js" type="text/javascript"></script>
    </head>
   
    <body id="page1" onload="MM_preloadImages('../images/tmpl/but_1_act.gif','../images/tmpl/but_2_act.gif','../images/tmpl/but_3_act.gif','../images/tmpl/but_4_act.gif','../images/tmpl/but_5_act.gif','../images/tmpl/but_6_act.gif')">
      <div id="site_center">
        <div class="tall_top">
          <div class="tall_bottom">
            <div id="main">
              <!-- header -->
              <div id="header">
                <div class="row_1">
                  <div class="column1">
                    <div class="indent">
                      <h1>Generalex</h1>
                    </div>
                  </div>
                  <div class="column2">
                    <div class="indent">
                      <a href="#">Sitemap</a>&nbsp; |&nbsp; <a href="index-5.html">Contacts</a>&nbsp; |&nbsp; <a href="#">Login</a>
                    </div>
                  </div>
                  <div class="clear"></div>
                </div>
                <div class="row_2">
                  <a href="index.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('r_1','','images/but_1_act.gif',1)"><img alt="" src="images/but_1_act.gif" id="r_1" /></a><img alt="" src="images/spacer.gif" width="2" height="1" /><a href="index-1.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('r_2','','images/but_2_act.gif',1)"><img alt="" src="images/but_2.gif" id="r_2" /></a><img alt="" src="images/spacer.gif" width="2" height="1" /><a href="index-2.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('r_3','','images/but_3_act.gif',1)"><img alt="" src="images/but_3.gif" id="r_3" /></a><img alt="" src="images/spacer.gif" width="2" height="1" /><a href="index-3.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('r_4','','images/but_4_act.gif',1)"><img alt="" src="images/but_4.gif" id="r_4" /></a><img alt="" src="images/spacer.gif" width="2" height="1" /><a href="index-4.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('r_5','','images/but_5_act.gif',1)"><img alt="" src="images/but_5.gif" id="r_5" /></a><img alt="" src="images/spacer.gif" width="2" height="1" /><a href="index-5.html" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('r_6','','images/but_6_act.gif',1)"><img alt="" src="images/but_6.gif" id="r_6" /></a>
                </div>
                <div class="row_3">
                  <div class="indent">
                    <img alt="" src="images/slogan.gif" /><br />
                    <a class="link1" href="#">Learn more info</a>
                  </div>
                </div>
              </div>
              <!-- content -->
              <div id="content">
                <div class="row_1">
                  <div class="col_1">
                    <a href="#"><img alt="" src="images/1_bann1.jpg" /></a>
                  </div>
                  <div class="col_2">
                    <a href="#"><img alt="" src="images/1_bann2.jpg" /></a>
                  </div>
                  <div class="clear"></div>
                </div>
                <div class="row_2">
                  <div class="indent">
                    <div class="wrapper">
                      <div class="col_1">
                        <div class="indent">
                          <div class="line_hor">
                            <img class="title" alt="" src="images/1_t1.gif" /><br />
                            <ul class="ul">
                              <li><a href="#">Aenean nonum myendrerit</a> maurihasellus portusce sesucurs ueifriu tibus </li>
                              <li><a href="#">Morbi nunc odcursu</a> ectus aloreecenas trisique orci esus eleifeseis</li>
                              <li><a href="#">Donec accumsan mal esuada</a> orcec sit ameesus eleifecursum ipsudolo</li>
                            </ul>
                          </div>
                          <h3>Lorem ipsum dolor sit amet, consean nonum endrerit mauris. Phase llus porta. Fusce suscipit varietugiat malesuer atuer adipiscindis.</h3>
                          <p>Aenean nonummyendrerit mauris. Phasellus portusce susarius mi. Cumiis qutibus et magnis dis partu rientntes, nascetur ridiculuulla du malda odio. Morbi nudcursu ectus aloreecenas trisiq orcec sit amet eros.</p>
                          <p class="p1">Lorem ipsum dolor stuer adipiscing elit. Ma mentum dictum magned laoreet aliuam leo. Ut tellubus eget, elemesus eleifend eli Aenean auctor wisi et urnam eratlutpais Integer rutrum ante eu lacuVestibulum libero nista vel.</p>
                          <a class="link1" href="#">Learn more info</a>
                        </div>
                      </div>
                      <div class="col_2">
                        <div class="indent">
                          <img class="title" alt="" src="images/1_t2.gif" /><br />
                          <a class="link1" href="#"><strong>12 05 2008</strong></a>
                          <p>Aenean nonummyendrerit maurissellus portusce susarius mi. Cumiis natopen atibus et magnis dis partu. <a href="#">more</a></p>
                          <a class="link1" href="#"><strong>12 05 2008</strong></a>
                          <p>Aenean nonummyendrerit maurissellus portusce susarius mi. Cumiis natopen atibus et magnis dis partu. <a href="#">more</a></p>
                          <a class="link1" href="#"><strong>12 05 2008</strong></a>
                          <p class="p1">Aenean nonummyendrerit maurissellus portusce susarius mi. Cumiis natopen atibus et magnis dis partu. <a href="#">more</a></p>
                          <a class="link1" href="#">Learn more news</a>
                        </div>
                      </div>
                      <div class="clear"></div>
                    </div>
                  </div>
                </div>
              </div>
              <!-- footer -->
              <div id="footer">
                <div class="indent">
                  <div class="fleft">
                    Console &copy; 2008 &bull; <a href="index-6.html">Privacy Policy</a>
                  </div>
                  <div class="fright">
                    <a class="rss_link1" href="#">subscribe</a>
                  </div>
                  <div class="clear"></div>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>   
    </body>
  </html>
 
</s:layout-definition>

this may be overkill, but i'm desperate as this is the last hurdle on this project. all other stripes pages that do not pass through the rules are happy





From: tfenne@...
Date: Wed, 2 Jul 2008 18:10:00 -0400
To: stripes-users@...
Subject: Re: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter(Its a bug)

The code that you have found comes from the LayoutDefinitionTag.  This tag should only ever occur on the page that defines the common layout (not on pages using that layout).  Because of this, certain assumptions are made:

1) Layout JSPs (those using s:layout-definition) are only ever executed by Stripes, and in fact by the layout-render tag.  You should not be forwarding to those yourself

2) The only way the s:layout-render tag ever executes the layout is via an INCLUDE

3) Therefore, when used properly, the call to find the include_path should work just fine

I'm not sure exactly what you're doing differently that is causing this problem.  Can you perhaps show us the JSP that is invoking the layout? 

-t

On Jul 2, 2008, at 5:42 PM, Farouk Alhassan wrote:

My reading of the servlet spec shows that, using getAttribute('javax.servlet.include.servlet_path')-which is the only method used by net.sourceforge.stripes.tag.layout.LayoutDefinitionTag.doStart() -will work only if the include was used. since you should be
able to forward to the jsp page before that page invokes the layout-definition using include, the above method will have a wrong value since the parameter will not be there. at this point, it will be under getAttribute("javax.servlet.forward.servlet_path"); I therefore think stripes should consider this as well since the relegation of the control to the jsp can come from anywhere.

I dont know how to fix this though


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 19:19:18 +0100
Subject: Re: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

a short section of my web.xml. the urlRewriter creates the name of the jsp file requested and forwards to it. Stripes intercepts the forward to do instantiation before jsp is written

  <filter-mapping>   
   <filter-name>UrlRewriteFilter</filter-name>
   <url-pattern>/*</url-pattern>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <url-pattern>/*</url-pattern>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>
 
  <filter-mapping>
    <filter-name>StripesFilter</filter-name>
    <servlet-name>StripesDispatcher</servlet-name>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
  </filter-mapping>


From: tfenne@...
Date: Wed, 2 Jul 2008 13:48:02 -0400
To: stripes-users@...
Subject: Re: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

Do you have the URLRewrite filter mapped only to the REQUEST dispatcher, or does it also kick in on INCLUDEs?  It sounds to me like the Stripes code is expected to only ever be called through an include, and in this case is not because something is intercepting in the middle and doing something else.  Is that the case?  And if so, is there any need to have the URLRewrite work on anything except requests coming in from outside the container?

-t

On Jul 2, 2008, at 1:41 PM, Farouk Alhassan wrote:

Hi guys, can someone help me here as i am stack.. a further debugging shows that  is definetily null. This may also be due to the fact the there is
confusion on the value returned by the

String name = (String) getPageContext().getRequest() .getAttribute('javax.servlet.include.servlet_path'); depending on whether its a include or a forward

http://www.caucho.com/resin-3.0/webapp/faq.xtp


From: gcameo@...
To: stripes-users@...
Date: Wed, 2 Jul 2008 08:07:03 +0100
Subject: [Stripes-users] Forwarding to a jsp that uses stripes taglib from a filter

I have an intercepting