diff options
| author | chrislu <chris.lu@gmail.com> | 2024-11-19 08:32:31 -0800 |
|---|---|---|
| committer | chrislu <chris.lu@gmail.com> | 2024-11-19 08:32:31 -0800 |
| commit | e28f55eb087c7390ac6c084d9d024685aacbe2dd (patch) | |
| tree | 570cd5aefc0398ee611aef3ef2f8c8ec40dde8f0 | |
| parent | 98f03862aab3540d2b71010ee0ce96a1d299cdc4 (diff) | |
| download | seaweedfs-e28f55eb087c7390ac6c084d9d024685aacbe2dd.tar.xz seaweedfs-e28f55eb087c7390ac6c084d9d024685aacbe2dd.zip | |
typo
| -rw-r--r-- | weed/shell/command_fs_merge_volumes.go | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/weed/shell/command_fs_merge_volumes.go b/weed/shell/command_fs_merge_volumes.go index 40033c190..d35f63c0a 100644 --- a/weed/shell/command_fs_merge_volumes.go +++ b/weed/shell/command_fs_merge_volumes.go @@ -226,29 +226,29 @@ func (c *commandFsMergeVolumes) createMergePlan(collection string, toVolumeId ne continue } for j := 0; j < i; j++ { - condidate := volumeIds[j] - if toVolumeId != 0 && condidate != toVolumeId { + candidate := volumeIds[j] + if toVolumeId != 0 && candidate != toVolumeId { continue } - if _, moving := plan[condidate]; moving { + if _, moving := plan[candidate]; moving { continue } - compatible, err := c.volumesAreCompatible(src, condidate) + compatible, err := c.volumesAreCompatible(src, candidate) if err != nil { return nil, err } if !compatible { - fmt.Printf("volume %d is not compatible with volume %d\n", src, condidate) + fmt.Printf("volume %d is not compatible with volume %d\n", src, candidate) continue } - if c.getVolumeSizeBasedOnPlan(plan, condidate)+c.getVolumeSizeById(src) > c.volumeSizeLimit { + if c.getVolumeSizeBasedOnPlan(plan, candidate)+c.getVolumeSizeById(src) > c.volumeSizeLimit { fmt.Printf("volume %d (%d MB) merge into volume %d (%d MB) exceeds volume size limit (%d MB)\n", src, c.getVolumeSizeById(src)/1024/1024, - condidate, c.getVolumeSizeById(condidate)/1024/1024, + candidate, c.getVolumeSizeById(candidate)/1024/1024, c.volumeSizeLimit/1024/1024) continue } - plan[src] = condidate + plan[src] = candidate break } } |
