aboutsummaryrefslogtreecommitdiff
path: root/weed/shell/command_ec_decode.go
diff options
context:
space:
mode:
authorjsh <sherking@hotmail.com>2023-11-09 17:04:18 +0800
committerChris Lu <chrislusf@users.noreply.github.com>2023-11-10 00:04:42 -0800
commit47112917ff2d2460a04582033435b9af048bebc0 (patch)
tree9ccbe79a87a44febc594ac55cd05c8fbc7e3641f /weed/shell/command_ec_decode.go
parent85bed4d92e3bbb44db6ac4e6d17a3d2e079c226b (diff)
downloadseaweedfs-47112917ff2d2460a04582033435b9af048bebc0.tar.xz
seaweedfs-47112917ff2d2460a04582033435b9af048bebc0.zip
ec.decode: mount the collected ec shards
Diffstat (limited to 'weed/shell/command_ec_decode.go')
-rw-r--r--weed/shell/command_ec_decode.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/weed/shell/command_ec_decode.go b/weed/shell/command_ec_decode.go
index aecc21065..aa0ca5045 100644
--- a/weed/shell/command_ec_decode.go
+++ b/weed/shell/command_ec_decode.go
@@ -197,6 +197,16 @@ func collectEcShards(commandEnv *CommandEnv, nodeToEcIndexBits map[pb.ServerAddr
return fmt.Errorf("copy %d.%v %s => %s : %v\n", vid, needToCopyEcIndexBits.ShardIds(), loc, targetNodeLocation, copyErr)
}
+ fmt.Printf("mount %d.%v on %s\n", vid, needToCopyEcIndexBits.ShardIds(), targetNodeLocation)
+ _, mountErr := volumeServerClient.VolumeEcShardsMount(context.Background(), &volume_server_pb.VolumeEcShardsMountRequest{
+ VolumeId: uint32(vid),
+ Collection: collection,
+ ShardIds: needToCopyEcIndexBits.ToUint32Slice(),
+ })
+ if mountErr != nil {
+ return fmt.Errorf("mount %d.%v on %s : %v\n", vid, needToCopyEcIndexBits.ShardIds(), targetNodeLocation, mountErr)
+ }
+
return nil
})