aboutsummaryrefslogtreecommitdiff
path: root/weed/shell/commands.go
diff options
context:
space:
mode:
authorchrislu <chris.lu@gmail.com>2022-03-26 13:33:17 -0700
committerchrislu <chris.lu@gmail.com>2022-03-26 13:33:17 -0700
commit21e08986317995a89274b5fc7dad80a42006bc16 (patch)
treeccc6f6a1c00282011697e7a7f004cfd78ec1362f /weed/shell/commands.go
parent4ba7127ab1bf8fa045d623d0c6293a083f209ad7 (diff)
downloadseaweedfs-21e08986317995a89274b5fc7dad80a42006bc16.tar.xz
seaweedfs-21e08986317995a89274b5fc7dad80a42006bc16.zip
refactor: change masters from a slice to a map
Diffstat (limited to 'weed/shell/commands.go')
-rw-r--r--weed/shell/commands.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/weed/shell/commands.go b/weed/shell/commands.go
index ec71edee0..3ff49f1d2 100644
--- a/weed/shell/commands.go
+++ b/weed/shell/commands.go
@@ -46,7 +46,7 @@ var (
func NewCommandEnv(options *ShellOptions) *CommandEnv {
ce := &CommandEnv{
env: make(map[string]string),
- MasterClient: wdclient.NewMasterClient(options.GrpcDialOption, pb.AdminShellClient, "", "", pb.ServerAddresses(*options.Masters).ToAddresses()),
+ MasterClient: wdclient.NewMasterClient(options.GrpcDialOption, pb.AdminShellClient, "", "", pb.ServerAddresses(*options.Masters).ToAddressMap()),
option: options,
}
ce.locker = exclusive_locks.NewExclusiveLocker(ce.MasterClient, "admin")