shell: volume.balance plan by ratio of fullness

This commit is contained in:
Chris Lu committed 2020-09-12 04:06:26 -07:00
1 parent c0ee78d2fa
commit d15682b4a1
2 files changed
+44 -39

No files matched your search

+4
View File
@@ -253,6 +253,10 @@ func mountEcShards(grpcDialOption grpc.DialOption, collection string, volumeId n
})
}
func divide(total, n int) float64 {
return float64(total) / float64(n)
}
func ceilDivide(total, n int) int {
return int(math.Ceil(float64(total) / float64(n)))
}