mirror of
https://github.com/minio/minio.git
synced 2025-11-09 05:34:56 -05:00
crawler: Missing folder heal check per set (#10876)
This commit is contained in:
@@ -246,6 +246,19 @@ func (m metaCacheEntries) resolve(r *metadataResolutionParams) (selected *metaCa
|
||||
return selected, selected != nil
|
||||
}
|
||||
|
||||
// firstFound returns the first found and the number of set entries.
|
||||
func (m metaCacheEntries) firstFound() (first *metaCacheEntry, n int) {
|
||||
for _, entry := range m {
|
||||
if entry.name != "" {
|
||||
n++
|
||||
if first == nil {
|
||||
first = &entry
|
||||
}
|
||||
}
|
||||
}
|
||||
return first, n
|
||||
}
|
||||
|
||||
// names will return all names in order.
|
||||
// Since this allocates it should not be used in critical functions.
|
||||
func (m metaCacheEntries) names() []string {
|
||||
|
||||
Reference in New Issue
Block a user