fix: Walk() should require quorum number of disks only (#9164)

This commit is contained in:
Harshavardhana 2020-03-18 20:56:07 -07:00 committed by GitHub
parent db2155551a
commit d45a1808f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 7 deletions

View File

@ -1642,11 +1642,10 @@ func (s *xlSets) Walk(ctx context.Context, bucket, prefix string, results chan<-
return
}
if quorumCount != s.drivesPerSet {
return
if quorumCount >= s.drivesPerSet/2 {
results <- entry.ToObjectInfo() // Read quorum exists proceed
}
results <- entry.ToObjectInfo()
// skip entries which do not have quorum
}
}()

View File

@ -1394,11 +1394,11 @@ func (z *xlZones) Walk(ctx context.Context, bucket, prefix string, results chan<
return
}
if quorumCount != zoneDrivesPerSet[zoneIndex] {
continue
if quorumCount >= zoneDrivesPerSet[zoneIndex]/2 {
results <- entry.ToObjectInfo() // Read quorum exists proceed
}
results <- entry.ToObjectInfo()
// skip entries which do not have quorum
}
}()