jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dpfis...@apache.org
Subject svn commit: r368779 - /incubator/jackrabbit/trunk/jackrabbit/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java
Date Fri, 13 Jan 2006 16:43:59 GMT
Author: dpfister
Date: Fri Jan 13 08:43:52 2006
New Revision: 368779

URL: http://svn.apache.org/viewcvs?rev=368779&view=rev
Log:
Check for referential integrity too strict: if a node is deleted
and then again added with same UUID it is still referenceable.

Modified:
    incubator/jackrabbit/trunk/jackrabbit/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java

Modified: incubator/jackrabbit/trunk/jackrabbit/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java
URL: http://svn.apache.org/viewcvs/incubator/jackrabbit/trunk/jackrabbit/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java?rev=368779&r1=368778&r2=368779&view=diff
==============================================================================
--- incubator/jackrabbit/trunk/jackrabbit/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java
(original)
+++ incubator/jackrabbit/trunk/jackrabbit/src/main/java/org/apache/jackrabbit/core/state/SharedItemStateManager.java
Fri Jan 13 08:43:52 2006
@@ -1082,7 +1082,10 @@
                         }
                         refs = getNodeReferences(refsId);
                     }
-                    if (refs.hasReferences()) {
+                    // in some versioning operations (such as restore) a node
+                    // may actually be deleted and then again added with the
+                    // same UUID, i.e. the node is still referenceable.  
+                    if (refs.hasReferences() && !changes.has(node.getId())) {
                         String msg = node.getId()
                                 + ": the node cannot be removed because it is still being
referenced.";
                         log.debug(msg);



Mime
View raw message