Deleted documents are reappearing after replication
Deleted documents reappeared after replication. How can this happen?
Deleted documents can reappear after replication under one of the following circumstances:
1. The purge interval is more frequent than the replication schedule.
If a document is deleted and the deletion stub is purged before replication, the other replica copy does not have the information that the document has been deleted and replicates the document just like a new document.
2. A document was modified on one database replica after it was deleted on another replica copy.
If a document gets modified on one replica copy of the database after it was deleted from another replica, the modified date on the existing document is newer and would overwrite the deletion stub (there is no replication conflict with deletion stubs, the document just reappears).
3. A document was modified more often than the deleted document
If a document gets modified more often on a replica copy than of the database with the deleted document, it will come back after replication even if it was deleted after the last modification. This is because the sequence number (number of modifications) takes precedence over the modified date - and since there can't be a conflict with a deletion stub it reappears after next replication.