Bug 1006257 - Restoring a node which has non-versionable children fails
Summary: Restoring a node which has non-versionable children fails
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Data Virtualization 6
Classification: JBoss
Component: ModeShape
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: CR1
: ---
Assignee: Horia Chiorean
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-10 10:25 UTC by Horia Chiorean
Modified: 2016-02-10 08:54 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-02-10 08:54:38 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker MODE-2034 0 Major Closed Can't do restore while a node has multiple chidren 2014-02-17 12:49:09 UTC

Description Horia Chiorean 2013-09-10 10:25:53 UTC
Create a node with a couple of non-versionable children and 2 checkpoints for that node (via versionManager.checkpoint). After that, attempting to restore version "1.0" produces an exception.

Comment 1 JBoss JIRA Server 2013-09-10 11:21:49 UTC
Horia Chiorean <hchiorea> made a comment on jira MODE-2034

Fixed the restore operation of a parent with 2 unversioned children.

[~angelo.chen] thanks for the submitted files, the fix is very similar to your changes.

Comment 2 JBoss JIRA Server 2013-09-10 12:36:13 UTC
Angelo Chen <angelo.chen> made a comment on jira MODE-2034

@Horia Chiorean, I'm not sure whether the rename has the same issue.
-                    // See if this child has been removed ...
-                    if (changes.isRemoved(next)) continue;
+                    // See if this child has been removed but not inserted ...
+                    if (changes.isRemoved(next) && changes.inserted(next.getKey()) == null) continue;

how about the child has been removed and renamed?

Comment 3 JBoss JIRA Server 2013-09-10 12:37:20 UTC
Angelo Chen <angelo.chen> made a comment on jira MODE-2034

@hchiorean, I'm not sure whether the rename has the same issue.
-                    // See if this child has been removed ...
-                    if (changes.isRemoved(next)) continue;
+                    // See if this child has been removed but not inserted ...
+                    if (changes.isRemoved(next) && changes.inserted(next.getKey()) == null) continue;

how about the child has been removed and renamed?

Comment 4 JBoss JIRA Server 2013-09-10 12:39:27 UTC
Horia Chiorean <hchiorea> made a comment on jira MODE-2034

[~angelo.chen]: a node should not appear both as removed and renamed, from a transient changes perspective. This is only specific to "orderBefore".

Comment 5 JBoss JIRA Server 2013-09-10 19:31:35 UTC
Randall Hauch <rhauch> made a comment on jira MODE-2034

Rebased and merged the PR into the 'master' branch. Leaving open to be cherry-picked onto '3.3.x-prod-ip6.0'.

Comment 11 JBoss JIRA Server 2013-10-24 09:20:59 UTC
Randall Hauch <rhauch> updated the status of jira MODE-2034 to Closed

Comment 12 belong 2013-11-19 23:18:42 UTC
Fixed before GA - setting to requires_doc_text- accordingly

Comment 13 Filip Nguyen 2014-02-17 12:49:03 UTC
Fix verified in GA.


Note You need to log in before you can comment on or make changes to this bug.