jackrabbit-oak-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Julian Reschke (Jira)" <j...@apache.org>
Subject [jira] [Updated] (OAK-8759) Allow renamed nodes to be merged by oak-upgrade
Date Mon, 02 Dec 2019 14:57:00 GMT

     [ https://issues.apache.org/jira/browse/OAK-8759?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Julian Reschke updated OAK-8759:
--------------------------------
    Fix Version/s:     (was: 1.10.7)
                       (was: 1.8.17)

> Allow renamed nodes to be merged by oak-upgrade
> -----------------------------------------------
>
>                 Key: OAK-8759
>                 URL: https://issues.apache.org/jira/browse/OAK-8759
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: upgrade
>    Affects Versions: 1.8.17, 1.10.6
>            Reporter: Stefan Bluhm
>            Priority: Minor
>
> This improvement request relates to oak-upgrade in combination with using the --merge-paths
flag.
> A merge will fail if the new repository already has a copy of the old repository and
a node at the source has been renamed. The renamed node would be copied over to the destination
repository which contains the node with the original name. Both share the same UUID and the
content merge will fail with an OakConstraint0030.
> Here is a use case:
>  # Production System: „/content/example“ is created.
>  # Production System is copied over prior to migration to Staging System.
>  # Production System: "/content/example" is renamed to "/content/example-backup".
>  # Production System:  "/content/example" is created with different content to before.
>  # java -jar crx2oak.jar --copy-binaries --src-datastore=/source/datastore --datastore=/destination/datastore
\
> --include-paths=/content --merge-paths=/content \
> /source /destination
> Current behaviour:
> oak-upgrade fails with this message:
> Caused by: org.apache.jackrabbit.oak.api.CommitFailedException: OakConstraint0030: Uniqueness
constraint violated property [jcr:uuid] having value 12345678-1234-1234-1234-123456789012:
/content/example-backup, /content/example
>  
> Desired behaviour:
> Option 1: If there are duplicate UUIDs, oak-upgrade should assume a rename so already
existing destination nodes should be dropped and the new one copied.
> Option 2: If there are duplicate UUIDs, oak-upgrade should assume a rename so already
existing destination nodes should be versioned and dropped and the new one copied.
>  
> Flags --copy-orphaned-versions and --copy-versions should be respected.



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

Mime
View raw message