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

Eduardo Perez Garcia commented on JCR-4680:
-------------------------------------------

I think this is the relevant section of the spec: [15.7.3 Restoring 
Properties|https://docs.adobe.com/content/docs/en/spec/jcr/2.0/15_Versioning.html#15.7.3%20Restoring%20Properties]

There the spec doesn't specify the order of the different operations, and then 
we could assume that when copying the mixins of the frozen node, non-applicable 
properties *already* will have been (should be) removed *before* evaluating the 
remaining properties.
It seems this problem doesn't exist from the spec point of view and instead 
it's the jackrabbit *implementation* that doesn't remove non-applicable 
properties *first* before doing the evaluation. So it looks like this is an 
issue with the implementation of the spec and not with the spec itself.

> ConstraintViolationException in VersionManagerImplRestore when target node 
> has a property definition unknown by the frozen node
> -------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: JCR-4680
>                 URL: https://issues.apache.org/jira/browse/JCR-4680
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: versioning
>    Affects Versions: 2.20.2
>            Reporter: Eduardo Perez Garcia
>            Priority: Major
>         Attachments: VersionManagerImplRestore.patch
>
>
> If we attempt to restore a frozen node from the version history, but the 
> target node has new property definitions (mixins), we get a 
> ConstraintViolationException because the properties of the new node are 
> processed after replacing its mixins with the mixins from the frozen node.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to