Browse Source
[master] Revert back automatic volume grow in case of compensate for crowded volumes (#6267)
brought back the Automatic Volume Grow to compensate for crowded volumes
pull/6288/head
Konstantin Lebedev
1 month ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
3 additions and
0 deletions
-
weed/server/master_grpc_server_volume.go
|
@ -71,6 +71,9 @@ func (ms *MasterServer) ProcessGrowRequest() { |
|
|
case mustGrow > 0: |
|
|
case mustGrow > 0: |
|
|
vgr.WritableVolumeCount = uint32(mustGrow) |
|
|
vgr.WritableVolumeCount = uint32(mustGrow) |
|
|
_, err = ms.VolumeGrow(ctx, vgr) |
|
|
_, err = ms.VolumeGrow(ctx, vgr) |
|
|
|
|
|
case lastGrowCount > 0 && writable < int(lastGrowCount*2) && float64(crowded+volumeGrowStepCount) > float64(writable)*topology.VolumeGrowStrategy.Threshold: |
|
|
|
|
|
vgr.WritableVolumeCount = volumeGrowStepCount |
|
|
|
|
|
_, err = ms.VolumeGrow(ctx, vgr) |
|
|
default: |
|
|
default: |
|
|
for _, dc := range dcs { |
|
|
for _, dc := range dcs { |
|
|
if vl.ShouldGrowVolumesByDataNode("DataCenter", dc) { |
|
|
if vl.ShouldGrowVolumesByDataNode("DataCenter", dc) { |
|
|