You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Dirk Rudolph (JIRA)" <ji...@apache.org> on 2016/08/05 08:24:20 UTC

[jira] [Commented] (SLING-5947) MockSlingHttpServletRequest used with SlingRequestProcessor causes UnsupportedOperationException

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

Dirk Rudolph commented on SLING-5947:
-------------------------------------

Same applies for {{getPathInfo()}}

> MockSlingHttpServletRequest used with SlingRequestProcessor causes UnsupportedOperationException
> ------------------------------------------------------------------------------------------------
>
>                 Key: SLING-5947
>                 URL: https://issues.apache.org/jira/browse/SLING-5947
>             Project: Sling
>          Issue Type: Bug
>          Components: Extensions
>    Affects Versions: Servlet Helpers 1.0.0
>            Reporter: Dirk Rudolph
>             Fix For: Servlet Helpers 1.0.2
>
>
> {{getServletPath()}} throws the UnsupportedOperationException in MockSlingHttpServletRequest
> http://svn.apache.org/viewvc/sling/trunk/bundles/extensions/servlet-helpers/src/main/java/org/apache/sling/servlethelpers/MockSlingHttpServletRequest.java?revision=1728734&view=markup#l685
> It gets called from the SlingHttpServletRequestImpl constructor 
> http://svn.apache.org/viewvc/sling/trunk/bundles/engine/src/main/java/org/apache/sling/engine/impl/SlingHttpServletRequestImpl.java?view=markup#l71
> causing the following stacktrace:
> {code}
> Caused by: java.lang.UnsupportedOperationException: null
>         at org.apache.sling.servlethelpers.MockSlingHttpServletRequest.getServletPath(MockSlingHttpServletRequest.java:685)
>         at org.apache.sling.engine.impl.SlingHttpServletRequestImpl.<init>(SlingHttpServletRequestImpl.java:71)
>         at org.apache.sling.engine.impl.request.RequestData$1.createRequest(RequestData.java:700)
>         at org.apache.sling.engine.impl.request.RequestData.<init>(RequestData.java:215)
>         at org.apache.sling.engine.impl.SlingRequestProcessorImpl.doProcessRequest(SlingRequestProcessorImpl.java:121)
>         at org.apache.sling.engine.impl.SlingRequestProcessorImpl.processRequest(SlingRequestProcessorImpl.java:247)
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)