Ok, I think we should just remove the catch from the SlingPropertyValueHandler as this is implementation specific. WIth Oak this execption will not be thrown in this place, but later on during the save where we obviously don't catch it (and can't).
Carsten 2013/4/16 Bertrand Delacretaz <[email protected]> > On Tue, Apr 16, 2013 at 9:40 AM, Carsten Ziegeler <[email protected]> > wrote: > > ...Looking at the comments of > > SLING-1619<https://issues.apache.org/jira/browse/SLING-1619>, > > I'm not sure if adding this check for the ConstraintViolationException > was > > the right thing to do anywa - there is not that much information in the > > issue to decide.... > > IIUC the problem is a client trying to set a jcr:created property to a > specific value, but that's set automatically by the repository on some > node types. > > IMO that should fail, but causing that to fail might be backwards > incompatible, including with the SlingPropertyValueHandler [1] which > will set a jcr:created property itself if it's present in its request. > I have just added a test in revision 1468358 that should detect > backwards incompatible changes to this behavior. > > -Bertrand > > [1] > https://svn.apache.org/repos/asf/sling/trunk/bundles/servlets/post/src/main/java/org/apache/sling/servlets/post/impl/helper/SlingPropertyValueHandler.java > -- Carsten Ziegeler [email protected]
