[
https://issues.apache.org/jira/browse/SLING-1089?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12746653#action_12746653
]
Ian Boston commented on SLING-1089:
-----------------------------------
Although responding with a 404 (or some other suitable response) will satisfy
http semantics, this will result in a non backward compatable change. I think
(from observation of developers) that the fact the DefaultGetServlet is called
Default implies that all request that are not handled by something more
specific are handled by this servlet. The impression is, that that goes for
situations where a selector of a view has not been implemented.
So the application created some optional selectors that applied special
rendering on GET requests, if the feature bundle containing that selector was
loaded. If not, the default rendering is used.
I think it all depends on what is considered to be the URI to the resource. Is
it the part up to the first dot in the last element... or is it the whole URL ?
I would need to check, but I think this change would break some of my features
based on Sling, but that does not mean that I am against the change as I can
adapt with relative ease.
> DefaultGetServlet should report an error if the selector string is not empty
> ----------------------------------------------------------------------------
>
> Key: SLING-1089
> URL: https://issues.apache.org/jira/browse/SLING-1089
> Project: Sling
> Issue Type: Bug
> Components: Servlets Get
> Affects Versions: Servlets Get 2.0.4
> Reporter: Eric Norman
> Attachments: SLING-1089_patch.txt
>
>
> The DefaultGetServlet will render a response whenever the extension matches
> one of the mapped renderer servlets. The selectors are not checked so the
> requesting user could put any arbitrary text as the selector and never get an
> error.
> For example, http://host/resource_path.txt would stream back the text
> representation of the resource. However,
> http://host/resource_path.some.made.up.selector.txt also streams back the
> same response.
> I would think it would be more correct for the DefaultGetServlet to only
> stream a response when the selectors are empty. If the selectors are not
> empty then the user loaded an invalid url, or there is a server-side script
> missing to handle the specified selector.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.