jakarta-cactus-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vincent Massol" <vmas...@octo.com>
Subject Re: [PATCH] Re: ServletRedirector mapping
Date Wed, 07 Nov 2001 11:38:42 GMT
Thanks Erik,

I should have mentionned that I have already patched the documentation
locally on my computer but was waiting for release 1.3 to put it on the web
site ? Why ? Because, if you remove the trailing "/" with Cactus 1.2, one of
the test will fail ... So, we would rightly get complaints from users saying
that they applied the doc from the web site and it doesn't work ...

Thanks
-Vincent

----- Original Message -----
From: "Erik Hatcher" <lists@ehatchersolutions.com>
To: "Cactus Users List" <cactus-user@jakarta.apache.org>; "Vincent Massol"
<vmassol@octo.com>
Sent: Wednesday, November 07, 2001 11:14 AM
Subject: [PATCH] Re: ServletRedirector mapping


> I guess I was just looking at outdated documentation then.  Note at the
> bottom of this page: http://jakarta.apache.org/cactus/howto_config.html it
> shows:
>
>     <url-pattern>/ServletRedirector/</url-pattern>
>
> That should be corrected.  I'll even go one step further and submit a
patch!
> :)
>
>     Erik
>
>
> ----- Original Message -----
> From: "Vincent Massol" <vmassol@octo.com>
> To: "Cactus Users List" <cactus-user@jakarta.apache.org>
> Sent: Wednesday, November 07, 2001 4:09 AM
> Subject: Re: ServletRedirector mapping
>
>
> >
> >
> > ----- Original Message -----
> > From: "Erik Hatcher" <lists@ehatchersolutions.com>
> > To: <cactus-user@jakarta.apache.org>
> > Sent: Monday, November 05, 2001 9:30 PM
> > Subject: ServletRedirector mapping
> >
> >
> > > This might be a cactus-dev issue, but I'll toss it out here since all
> > > relevant parties are on this list also.  In order to get Cactus
working,
> I
> > > had to modify the servlet mapping to have "/*" rather than "/" at the
> end
> > of
> > > ServletRedirector, like this:
> > >
> > >     <servlet-mapping>
> > >         <servlet-name>ServletRedirector</servlet-name>
> > >         <url-pattern>/ServletRedirector/*</url-pattern>
> > >     </servlet-mapping>
> > >
> > > Servlet 2.2 spec says this:
> > >
> > > 10.2 Specification of Mappings
> > > In the web application deployment descriptor, the following syntax is
> used
> > > to define mappings:
> > > . A string beginning with a '/' character and ending with a '/*'
postfix
> > is
> > > used as a path mapping.
> > > . A string beginning with a '*.' prefix is used as an extension
mapping.
> > > . All other strings are used as exact matches only
> > > . A string containing only the '/' character indicates that servlet
> > > specified by the mapping becomes the "default" servlet of the
> application.
> > >
> > > So it seems the Cactus mapping of ServletRedirector is not compliant
> with
> > > the spec.  A quick glance at the Servlet 2.3 spec appears to say the
> same
> > > thing as the 2.2 spec.
> > >
> > > Is there any reason not to put the "/*" at the end?  It makes it work
in
> > > WebSphere at least!  :)  Are all the other containers Cactus just
> implying
> > > the "*"?
> >
> > I have tried Cactus on 10 different servlet engines and they all worked
> with
> > "/ServletRedirector" (forget "/ServletRedirector/" which is no longer
> valid
> > in Cactus 1." - and doesn't work if you're passing parameters). The
reason
> > is that the ServletRedirector is not meant as a path but as the last
> element
> > in the URL (exact match). So "/ServletRedirector/*" would work but would
> > fire for urls such as ".../ServletRedirector/something/other?xxx=yyy".
> > However, we want the last element in the URL to be the redirector. so
> > "/ServletRedirector" should work on all engines.
> >
> > > I haven't dug into Cactus code to see how it fires things to the
> > > ServletRedirector - is it sending a GET string to it?  Or just hitting
> > > /ServletRedirector directly using POST and now URL parameters?
> > >
> >
> > it uses the url in cactus.properties and either a post or get depending
on
> > whether the user has set post parameters in WebRequest.
> >
> > > Thanks,
> > >     Erik
> > >
> >
> > Thanks
> > -Vincent
> >
> >
> > --
> > To unsubscribe, e-mail:
> <mailto:cactus-user-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail:
> <mailto:cactus-user-help@jakarta.apache.org>
> >
> >
>


--
To unsubscribe, e-mail:   <mailto:cactus-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:cactus-user-help@jakarta.apache.org>


Mime
View raw message