[
https://issues.apache.org/jira/browse/SLING-8182?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16722939#comment-16722939
]
Konrad Windszus edited comment on SLING-8182 at 12/17/18 1:59 PM:
------------------------------------------------------------------
Basically each servlet (but not the script) is registered via its own
{{ServletResourceProvider}}. The service.ranking is inherited from the
underlying servlet service (compare with
https://github.com/apache/sling-org-apache-sling-servlets-resolver/blob/e12a403c994f7899f4978a9b6e26a9a07f39e348/src/main/java/org/apache/sling/servlets/resolver/internal/resource/ServletMounter.java#L248).
Each potential servlet is then looked up from the resource tree via the
{{LocationIterator}}
was (Author: kwin):
Basically each servlet is registered via its own {{ServletResourceProvider}}.
The service.ranking is inherited from the underlying servlet service (compare
with
https://github.com/apache/sling-org-apache-sling-servlets-resolver/blob/e12a403c994f7899f4978a9b6e26a9a07f39e348/src/main/java/org/apache/sling/servlets/resolver/internal/resource/ServletMounter.java#L248).
Each potential servlet is then looked up from the resource tree via the
{{LocationIterator}}
> Add documentation about servlet resolution order
> ------------------------------------------------
>
> Key: SLING-8182
> URL: https://issues.apache.org/jira/browse/SLING-8182
> Project: Sling
> Issue Type: Improvement
> Components: Documentation
> Reporter: Konrad Windszus
> Priority: Major
>
> The documentation at
> https://sling.apache.org/documentation/the-sling-engine/servlets.html#servlet-registration
> should include a paragraph about the order in which potential matching
> servlets/scripts are considered.
> Aspects to be covered:
> * Consideration of property {{service.ranking}}
> * Amount of matching selectors and extension
> * Location of the matching resource type in the inheritance tree
> * OptingServlet vs. regular servlet
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)