diff options
author | Colin Marc <hi@colinmarc.com> | 2022-02-05 13:56:01 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-02-05 13:56:01 +0100 |
commit | 154bbe76f0463b6b4e6587659af6f954680456a7 (patch) | |
tree | d4a34dbea064f836957958a54069d9c4c256bd45 | |
parent | f0bdd6222a3816060c4a0a1f27968516d22d3c24 (diff) | |
parent | 5574f534442a102a6af32aa8ec4a6ebc81315328 (diff) |
Merge pull request #272 from dotzero/master
Allow to use multiple nodes in HADOOP_NAMENODE
-rwxr-xr-x | cmd/hdfs/main.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd/hdfs/main.go b/cmd/hdfs/main.go index dc7f0b4..b9106b8 100755 --- a/cmd/hdfs/main.go +++ b/cmd/hdfs/main.go @@ -6,6 +6,7 @@ import ( "net" "os" "os/user" + "strings" "time" "github.com/colinmarc/hdfs/v2" @@ -189,7 +190,7 @@ func getClient(namenode string) (*hdfs.Client, error) { options := hdfs.ClientOptionsFromConf(conf) if namenode != "" { - options.Addresses = []string{namenode} + options.Addresses = strings.Split(namenode, ",") } if options.Addresses == nil { |