Browse Source

volume: file counter should be all files

address https://github.com/seaweedfs/seaweedfs/pull/3388#issuecomment-1220466228
pull/3472/head
chrislu 2 years ago
parent
commit
c7892bc7c4
  1. 3
      weed/storage/needle_map_metric.go

3
weed/storage/needle_map_metric.go

@ -105,9 +105,8 @@ func newNeedleMapMetricFromIndexFile(r *os.File) (mm *mapMetric, err error) {
mm.FileByteCounter += uint64(size)
}
if !bf.TestAndAdd(buf) {
mm.FileCounter++
} else {
if bf.TestAndAdd(buf) {
// deleted file
mm.DeletionCounter++
if size.IsValid() {

Loading…
Cancel
Save