- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for GetValueWithQuorum (0.13 sec)
-
cmd/erasure-metadata-utils.go
"hash/crc32" "github.com/minio/pkg/v3/sync/errgroup" ) // counterMap type adds GetValueWithQuorum method to a map[T]int used to count occurrences of values of type T. type counterMap[T comparable] map[T]int // GetValueWithQuorum returns the first key which occurs >= quorum number of times. func (c counterMap[T]) GetValueWithQuorum(quorum int) (T, bool) { var zero T for x, count := range c { if count >= quorum {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri May 24 23:05:23 UTC 2024 - 11.7K bytes - Viewed (0) -
cmd/erasure-metadata.go
} otherPropsMap[props]++ } } } if found { // Update candidate FileInfo with succModTime and numVersions in quorum when available if props, ok := otherPropsMap.GetValueWithQuorum(quorum); ok { candidate.SuccessorModTime = props.succModTime candidate.IsLatest = props.succModTime.IsZero() candidate.NumVersions = props.numVersions } return candidate, nil }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Oct 31 22:10:24 UTC 2024 - 21.3K bytes - Viewed (0)