jfc wrote: > Cox, Charlie wrote: > >> would RequestDispather.forward() work for you? you can use this from >> within >> your filter and it will not reinvoke the authentication. >> >> Charlie >> >>> -----Original Message----- >>> From: jfc [mailto:[EMAIL PROTECTED]] >>> Sent: Tuesday, September 03, 2002 9:26 AM >>> To: Tomcat Users List >>> Subject: Re: altering the request URI in a filter >>> >>> >>> Martin Cooper wrote: >>> >>>>> -----Original Message----- >>>>> From: jfc [mailto:[EMAIL PROTECTED]] >>>>> Sent: Monday, September 02, 2002 1:51 AM >>>>> To: Tomcat Users List >>>>> Subject: Re: altering the request URI in a filter >>>>> >>>>> >>>> [snip] >>>> >>>>> Hi, >>>>> >>>>> Thanks for the reply. How can I actually set the new value/s on >>>>> the request? I don't see any setter methods or any fields which >>>>> can be used to hold the new value. >>>>> >>>>> The only setters I can see are setAttribute and setRequest. >>>>> >>>> Since you're the one implementing the wrapper class, you can >>> >>> choose to add >>> >>>> whatever methods you see fit. >>>> >>>> -- >>>> Martin Cooper >>>> >>>> >>>>> jfc >>>>> >>>>> >>>>> >>>>> -- >>>>> To unsubscribe, e-mail: >>>>> <mailto:[EMAIL PROTECTED]> >>>>> For additional commands, e-mail: >>>>> <mailto:[EMAIL PROTECTED]> >>>>> >>>>> >>>> >>>> -- >>>> To unsubscribe, e-mail: >>> >>> <mailto:[EMAIL PROTECTED]> >>> >>>> For additional commands, e-mail: >>> >>> <mailto:[EMAIL PROTECTED]> >>> >>>> >>> Hi Martin, >>> >>> If I create a request wrapper, I can add whatever state and accessor >>> or other methods which may be useful to some other process that >>> knows that they are there. What I am really asking is this: >>> >>> Because I am using struts, I have a ActionServlet and a request >>> processor which based on the request's stored URI, locates a mapping >>> which is defined in struts-config.xml and this mapping directs to a >>> handler (my action class). I want to be able to change the URI (the >>> one which the framework uses to locate the mapping) so that a >>> different mapping will be selected. >>> >>> So I'm not talking about adding specific behaviour or state to the >>> request - I want to access the existing state and modify it and have >>> the framework go about it's usual business of doing the delegating >>> to my action etc (based on the updated state). >>> >>> It is possible to override the ActionServlet and/or the request >>> processor in struts which may or may not be neccessary - depending >>> on what can be achieved from a filter. >>> >>> So I want to know where I could alter the request URI with this >>> change being visible to what ever processes the request to select >>> the struts mapping. >>> >>> >>> cheers >>> jfc >>> >>> >>> >>> >>> -- >>> To unsubscribe, e-mail: >>> <mailto:[EMAIL PROTECTED]> >>> For additional commands, e-mail: >>> <mailto:[EMAIL PROTECTED]> >>> >> >> -- >> To unsubscribe, e-mail: >> <mailto:[EMAIL PROTECTED]> >> For additional commands, e-mail: >> <mailto:[EMAIL PROTECTED]> >> >> > I'm getting > > java.lang.IllegalStateException: Cannot forward after response has > been committed > > ... etc > > At the end of my filter's doFilter method I am doing the following: > > if(stripped){ > RequestDispatcher rd = > request.getRequestDispatcher(requestURI); > if(rd != null){ > rd.forward(request, response); > } > } > chain.doFilter(request, response); > > Do I need to invoke the chainFilter?
Sorry that should be Do I need to invoke the chain.doFilter method? > > jfc > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
