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

Konrad Windszus edited comment on SLING-6515 at 3/19/17 2:52 PM:
-----------------------------------------------------------------

Even if the new exception would contain as cause the original exception, this 
would not be given out via HTMLResponse or JSONResponse, because both just call 
someObject.toString(). {{Throwable.toString()}} does not expose the wrapped 
exception though, see 
https://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html#toString(). 
I am wondering, why wrapping the exception is necessary at all.


was (Author: kwin):
Even if the new message would contain as cause the original exception, this 
would not be given out via HTMLResponse or JSONResponse, because both just call 
Property.toString(). {{Throwable.toString()}} does not expose the wrapped 
exception though, see 
https://docs.oracle.com/javase/7/docs/api/java/lang/Throwable.html#toString(). 
I am wondering, why wrapping the exception is necessary at all.

> Sling Post Processor considering validation model as well
> ---------------------------------------------------------
>
>                 Key: SLING-6515
>                 URL: https://issues.apache.org/jira/browse/SLING-6515
>             Project: Sling
>          Issue Type: Improvement
>          Components: Validation
>            Reporter: Konrad Windszus
>
> It should be possible to optionally enable a Sling Post Processor which 
> validates the incoming parameters against a validation model. In case the 
> incoming parameters are not valid, there must be an error response. 



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to