From fe4c8ab9a1c15ab0965d235bb9eccbf587cfc93e Mon Sep 17 00:00:00 2001
From: gbellato <gbellato@localhost>
Date: Fri, 06 Jul 2007 07:06:10 +0000
Subject: [PATCH] fix for 1898 : Conflicts between moddn and del generate server errors

---
 opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java b/opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java
index bf943ad..3118ed8 100644
--- a/opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java
+++ b/opends/src/server/org/opends/server/replication/plugin/ReplicationDomain.java
@@ -1612,6 +1612,17 @@
   // get the current DN of this entry in the database.
   DN currentDN = findEntryDN(entryUid);
 
+  if (currentDN == null)
+  {
+    // The entry targetted by the Modify DN is not in the database
+    // anymore.
+    // This is a conflict between a delete and this modify DN.
+    // The entry has been deleted anymore so we can safely assume
+    // that the operation is completed.
+    numResolvedNamingConflicts.incrementAndGet();
+    return true;
+  }
+
   // if the newDN and the current DN match then the operation
   // is a no-op (this was probably a second replay)
   // don't do anything.

--
Gitblit v1.10.0