fix: skipping checking active volumes with the same number of files at the moment (#4893)

* fix: skipping checking active volumes with the same number of files at the moment
 https://github.com/seaweedfs/seaweedfs/issues/4140

* refactor with comments
https://github.com/seaweedfs/seaweedfs/issues/4140

* add TestShouldSkipVolume

---------

Co-authored-by: Konstantin Lebedev <9497591+kmlebedev@users.noreply.github.co>
This commit is contained in:
Konstantin Lebedev
2023-10-09 21:57:26 +05:00
committed by GitHub
parent 3fe00996b2
commit 2b3e39397e
8 changed files with 1106 additions and 900 deletions

View File

@@ -240,6 +240,8 @@ func (vs *VolumeServer) VolumeStatus(ctx context.Context, req *volume_server_pb.
volumeSize, _, _ := v.DataBackend.GetStat()
resp.IsReadOnly = v.IsReadOnly()
resp.VolumeSize = uint64(volumeSize)
resp.FileCount = v.FileCount()
resp.FileDeletedCount = v.DeletedCount()
return resp, nil
}