SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.
Go blob-storagecloud-drivedistributed-file-systemdistributed-storageerasure-codingfusehadoop-hdfshdfskuberneteslancelancedbobject-storageposixs3s3-storageseaweedfstiered-file-systemvector-search
simplify
chrisluca042bd067a7
diff --git a/weed/shell/command_volume_balance_test.go b/weed/shell/command_volume_balance_test.goindex ce0aeb5ab6..d533269a4e 100644--- a/weed/shell/command_volume_balance_test.go+++ b/weed/shell/command_volume_balance_test.go@@ -264,7 +264,7 @@ func TestBalance(t *testing.T) {func TestVolumeSelection(t *testing.T) {topologyInfo := parseOutput(topoData)- vids, err := collectVolumeIdsForTierChange(nil, topologyInfo, 1000, types.ToDiskType("hdd"), "", 20.0, 0)+ vids, err := collectVolumeIdsForTierChange(topologyInfo, 1000, types.ToDiskType("hdd"), "", 20.0, 0)if err != nil {t.Errorf("collectVolumeIdsForTierChange: %v", err)}diff --git a/weed/shell/command_volume_tier_move.go b/weed/shell/command_volume_tier_move.goindex bf41c2ea07..e6cf4ee025 100644--- a/weed/shell/command_volume_tier_move.go+++ b/weed/shell/command_volume_tier_move.go@@ -88,7 +88,7 @@ func (c *commandVolumeTierMove) Do(args []string, commandEnv *CommandEnv, writer}// collect all volumes that should change- volumeIds, err := collectVolumeIdsForTierChange(commandEnv, topologyInfo, volumeSizeLimitMb, fromDiskType, *collectionPattern, *fullPercentage, *quietPeriod)+ volumeIds, err := collectVolumeIdsForTierChange(topologyInfo, volumeSizeLimitMb, fromDiskType, *collectionPattern, *fullPercentage, *quietPeriod)if err != nil {return err}@@ -279,7 +279,7 @@ func (c *commandVolumeTierMove) doMoveOneVolume(commandEnv *CommandEnv, writer ireturn nil}-func collectVolumeIdsForTierChange(commandEnv *CommandEnv, topologyInfo *master_pb.TopologyInfo, volumeSizeLimitMb uint64, sourceTier types.DiskType, collectionPattern string, fullPercentage float64, quietPeriod time.Duration) (vids []needle.VolumeId, err error) {+func collectVolumeIdsForTierChange(topologyInfo *master_pb.TopologyInfo, volumeSizeLimitMb uint64, sourceTier types.DiskType, collectionPattern string, fullPercentage float64, quietPeriod time.Duration) (vids []needle.VolumeId, err error) {quietSeconds := int64(quietPeriod / time.Second)nowUnixSeconds := time.Now().Unix()