diff --git a/cmd/bucket-replication.go b/cmd/bucket-replication.go index 7a82c0c61..b3e012146 100644 --- a/cmd/bucket-replication.go +++ b/cmd/bucket-replication.go @@ -517,8 +517,8 @@ func replicateDeleteToTarget(ctx context.Context, dobj DeletedObjectReplicationI } return } - // early return if already replicated delete marker for existing object replication - if dobj.DeleteMarkerVersionID != "" && dobj.OpType == replication.ExistingObjectReplicationType { + // early return if already replicated delete marker for existing object replication/ healing delete markers + if dobj.DeleteMarkerVersionID != "" && (dobj.OpType == replication.ExistingObjectReplicationType || dobj.OpType == replication.HealReplicationType) { if _, err := tgt.StatObject(ctx, tgt.Bucket, dobj.ObjectName, miniogo.StatObjectOptions{ VersionID: versionID, Internal: miniogo.AdvancedGetOptions{ @@ -526,10 +526,8 @@ func replicateDeleteToTarget(ctx context.Context, dobj DeletedObjectReplicationI }}); isErrMethodNotAllowed(ErrorRespToObjectError(err, dobj.Bucket, dobj.ObjectName)) { if dobj.VersionID == "" { rinfo.ReplicationStatus = replication.Completed - } else { - rinfo.VersionPurgeStatus = Complete + return } - return } } diff --git a/cmd/data-scanner.go b/cmd/data-scanner.go index db1e72675..2857994e4 100644 --- a/cmd/data-scanner.go +++ b/cmd/data-scanner.go @@ -1269,6 +1269,7 @@ func (i *scannerItem) healReplicationDeletes(ctx context.Context, o ObjectLayer, DeleteMarker: roi.DeleteMarker, }, Bucket: roi.Bucket, + OpType: replication.HealReplicationType, } if roi.ExistingObjResync.mustResync() { doi.OpType = replication.ExistingObjectReplicationType