[ 
https://issues.apache.org/jira/browse/SLING-7759?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16529841#comment-16529841
 ] 

Julian Sedding commented on SLING-7759:
---------------------------------------

[~npeltier] I don't think we should change the names of the servlet 
registration properties, because they are an documented and widely used API 
(you'r probably not suggesting we do this, but just in case). Therefore, I 
don't think it makes sense to name only the filter-specific properties 
{{sling.request.\*}}, as the reasoning would not be obvious to the user. 
Anyway, what is the issue with calling them {{sling.filter.\*}}?

Of course we should also keep the existing {{sling.filter.pattern}} property - 
if nothing else for backward-compatibility.

Regarding [~bdelacretaz]'s concern of AND vs OR, I think we should mimic what 
we do for servlets. IIRC this is basically an OR. If a user requires AND logic, 
they can still enforce that in their implementation, whilst benefiting from 
OR-based pre-selection.

bq. ... "registration properties" for a servlet or a filter should not be the 
same exactly

No, of course not. Servlet properties are already named {{sling.servlet.\*}}, 
registration properties for filters could (should?) be named 
{{sling.filter.\*}}.

> add other "patterns" than path for filters
> ------------------------------------------
>
>                 Key: SLING-7759
>                 URL: https://issues.apache.org/jira/browse/SLING-7759
>             Project: Sling
>          Issue Type: Improvement
>          Components: Engine
>    Affects Versions: Engine 2.6.12
>            Reporter: Nicolas Peltier
>            Assignee: Nicolas Peltier
>            Priority: Major
>
> adding additional patterns to filters (right now {{sling.filter.pattern}} 
> allows to include them based on path only):
> - path passes if sling.filter.pattern (i propose we keep it for legacy &  add 
> sling.filter.pattern.path for consistency with what follow) regexp matches 
> current path,
> - selector passes if sling.filter.pattern.selector is in the selector chain,
> - method passes if sling.filter.pattern.method is equals to curren method,
> - suffix  passes if sling.filter.pattern.suffix regep matches current suffix



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to