mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
avoid old values when missing read only flags
This commit is contained in:
parent
da36abf033
commit
2fb1fce8a0
|
@ -222,6 +222,10 @@ func (s *Store) CollectHeartbeat() *master_pb.Heartbeat {
|
||||||
collectionVolumeSize[v.Collection] += volumeMessage.Size
|
collectionVolumeSize[v.Collection] += volumeMessage.Size
|
||||||
if v.IsReadOnly() {
|
if v.IsReadOnly() {
|
||||||
collectionVolumeReadOnlyCount[v.Collection] += 1
|
collectionVolumeReadOnlyCount[v.Collection] += 1
|
||||||
|
} else {
|
||||||
|
if _, exist := collectionVolumeReadOnlyCount[v.Collection]; !exist {
|
||||||
|
collectionVolumeReadOnlyCount[v.Collection] = 0
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
location.volumesLock.RUnlock()
|
location.volumesLock.RUnlock()
|
||||||
|
|
Loading…
Reference in a new issue