aboutsummaryrefslogtreecommitdiff
path: root/weed/command/filer.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/command/filer.go
parent4ba7127ab1bf8fa045d623d0c6293a083f209ad7 (diff)
downloadseaweedfs-21e08986317995a89274b5fc7dad80a42006bc16.tar.xz
seaweedfs-21e08986317995a89274b5fc7dad80a42006bc16.zip
refactor: change masters from a slice to a map
Diffstat (limited to 'weed/command/filer.go')
-rw-r--r--weed/command/filer.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/weed/command/filer.go b/weed/command/filer.go
index 4f8fd947a..0a768944b 100644
--- a/weed/command/filer.go
+++ b/weed/command/filer.go
@@ -29,7 +29,7 @@ var (
)
type FilerOptions struct {
- masters []pb.ServerAddress
+ masters map[string]pb.ServerAddress
mastersString *string
ip *string
bindIp *string
@@ -171,7 +171,7 @@ func runFiler(cmd *Command, args []string) bool {
}()
}
- f.masters = pb.ServerAddresses(*f.mastersString).ToAddresses()
+ f.masters = pb.ServerAddresses(*f.mastersString).ToAddressMap()
f.startFiler()