better logging for volume growth

This commit is contained in:
chrislu
2024-09-07 12:38:34 -07:00
parent accba3070a
commit ff3d46637d
5 changed files with 11 additions and 3 deletions

View File

@@ -301,7 +301,7 @@ func (vl *VolumeLayout) PickForWrite(count uint64, option *VolumeGrowOption) (vi
lenWriters := len(vl.writables)
if lenWriters <= 0 {
return 0, 0, nil, true, fmt.Errorf("%s in volume layout", noWritableVolumes)
return 0, 0, nil, true, fmt.Errorf("%s", noWritableVolumes)
}
if option.DataCenter == "" && option.Rack == "" && option.DataNode == "" {
vid := vl.writables[rand.Intn(lenWriters)]