allow preserving legacyXLv1 with inline data format (#11951)

current master breaks this important requirement
we need to preserve legacyXLv1 format, this is simply
ignored and overwritten causing a myriad of issues
by leaving stale files on the namespace etc.

for now lets still use the two-phase approach of
writing to `tmp` and then renaming the content to
the actual namespace.
This commit is contained in:
Harshavardhana
2021-04-01 22:12:03 -07:00
committed by GitHub
parent 204c610d84
commit 434e5c0cfe
6 changed files with 148 additions and 94 deletions

View File

@@ -64,11 +64,14 @@ const (
// Detects change in underlying disk.
type xlStorageDiskIDCheck struct {
storage StorageAPI
diskID string
apiCalls [storageMetricLast]uint64
// fields position optimized for memory please
// do not re-order them, if you add new fields
// please use `fieldalignment ./...` to check
// if your changes are not causing any problems.
storage StorageAPI
apiLatencies [storageMetricLast]ewma.MovingAverage
diskID string
apiCalls [storageMetricLast]uint64
}
func (p *xlStorageDiskIDCheck) getMetrics() DiskMetrics {