Update detection.go

This commit is contained in:
Chris Lu
2026-01-23 21:38:51 -08:00
parent 6394e2f6a5
commit d3f79d4c38

View File

@@ -249,6 +249,11 @@ func planBalanceDestination(activeTopology *topology.ActiveTopology, selectedVol
bestScore := -1.0
for _, disk := range availableDisks {
// Ensure disk type matches
if disk.DiskType != selectedVolume.DiskType {
continue
}
score := calculateBalanceScore(disk, sourceRack, sourceDC, selectedVolume.Size)
if score > bestScore {
bestScore = score