grow volumes on volume servers with slots freed by cloud storage

This commit is contained in:
Chris Lu
2019-12-03 21:36:42 -08:00
parent 7ae8b1cc86
commit e426bd541e
11 changed files with 226 additions and 145 deletions

View File

@@ -64,6 +64,10 @@ func NewVolumeInfoFromShort(m *master_pb.VolumeShortInformationMessage) (vi Volu
return vi, nil
}
func (vi VolumeInfo) IsRemote() bool {
return vi.RemoteStorageName != ""
}
func (vi VolumeInfo) String() string {
return fmt.Sprintf("Id:%d, Size:%d, ReplicaPlacement:%s, Collection:%s, Version:%v, FileCount:%d, DeleteCount:%d, DeletedByteCount:%d, ReadOnly:%v",
vi.Id, vi.Size, vi.ReplicaPlacement, vi.Collection, vi.Version, vi.FileCount, vi.DeleteCount, vi.DeletedByteCount, vi.ReadOnly)