mirror of
https://github.com/minio/minio.git
synced 2025-11-09 21:49:46 -05:00
Set disk to nil after write which needs quorum (#3795)
Ignore a disk which wasn't able to successfully perform an action to avoid eventual perturbations when the disk comes back in the middle of write change.
This commit is contained in:
committed by
Harshavardhana
parent
461b2bbd37
commit
dce0345f8f
@@ -361,6 +361,8 @@ func writeUniqueXLMetadata(disks []StorageAPI, bucket, prefix string, xlMetas []
|
||||
err := writeXLMetadata(disk, bucket, prefix, xlMetas[index])
|
||||
if err != nil {
|
||||
mErrs[index] = err
|
||||
// Ignore disk which returned an error.
|
||||
disks[index] = nil
|
||||
}
|
||||
}(index, disk)
|
||||
}
|
||||
@@ -399,6 +401,8 @@ func writeSameXLMetadata(disks []StorageAPI, bucket, prefix string, xlMeta xlMet
|
||||
err := writeXLMetadata(disk, bucket, prefix, metadata)
|
||||
if err != nil {
|
||||
mErrs[index] = err
|
||||
// Ignore disk which returned an error.
|
||||
disks[index] = nil
|
||||
}
|
||||
}(index, disk, xlMeta)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user