You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@sling.apache.org by Carl Hall <ca...@hallwaytech.com> on 2010/08/04 16:05:18 UTC
servlet paths & resource types
On this page [1], it states that if the sling.servlet.paths is set,
sling.servlet.resourceTypes
is ignored. In the javadoc for ServletResolverConstants, it states that
both can be defined and the servlet will be registered under both. Which is
correct?
Also, the javadoc on @SlingServlet is a copy/paste ball of confusion. :-)
1 http://sling.apache.org/site/servlets.html
Re: servlet paths & resource types
Posted by Felix Meschberger <fm...@gmail.com>.
Hi,
On 06.08.2010 15:37, Bertrand Delacretaz wrote:
> Hi,
>
> On Wed, Aug 4, 2010 at 4:05 PM, Carl Hall <ca...@hallwaytech.com> wrote:
>> On this page [1], it states that if the sling.servlet.paths is set,
>> sling.servlet.resourceTypes
>> is ignored. In the javadoc for ServletResolverConstants, it states that
>> both can be defined and the servlet will be registered under both. Which is
>> correct?...
>
> I don't know off the top of my head, I'd say the automated tests
> linked from http://sling.apache.org/site/servlets.html are the
> Absolute Truth about this.
Well, then there is probably the Ultimate Truth which is the
implementation code itself ;-)
But yes, the automated tests help alot.
Regards
Felix
> If you're not sure how things work, the
> best would be to contribute some new tests there, unless the existing
> one demonstrate what you need.
>
> -Bertrand
>
Re: servlet paths & resource types
Posted by Bertrand Delacretaz <bd...@apache.org>.
Hi,
On Wed, Aug 4, 2010 at 4:05 PM, Carl Hall <ca...@hallwaytech.com> wrote:
> On this page [1], it states that if the sling.servlet.paths is set,
> sling.servlet.resourceTypes
> is ignored. In the javadoc for ServletResolverConstants, it states that
> both can be defined and the servlet will be registered under both. Which is
> correct?...
I don't know off the top of my head, I'd say the automated tests
linked from http://sling.apache.org/site/servlets.html are the
Absolute Truth about this. If you're not sure how things work, the
best would be to contribute some new tests there, unless the existing
one demonstrate what you need.
-Bertrand
Re: servlet paths & resource types
Posted by Felix Meschberger <fm...@gmail.com>.
Hi,
On 04.08.2010 16:05, Carl Hall wrote:
> On this page [1], it states that if the sling.servlet.paths is set,
> sling.servlet.resourceTypes
> is ignored. In the javadoc for ServletResolverConstants, it states that
> both can be defined and the servlet will be registered under both. Which is
> correct?
The page [1] used to be correct but over time we realized that it would
be usefull to have both approaches in paralell. Thus the JavaDoc is now
correct.
I will fix the servlets.html page.
Thanks for pointing out.
> Also, the javadoc on @SlingServlet is a copy/paste ball of confusion. :-)
Oh yeah ! Will fix this, too.
Regards
Felix
>
> 1 http://sling.apache.org/site/servlets.html
>