diff options
| author | Chris Lu <chris.lu@gmail.com> | 2017-02-12 21:58:44 -0800 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2017-02-12 21:58:44 -0800 |
| commit | 41f686ab9d8aaa94dc6e8c6746ecd7f63bc98506 (patch) | |
| tree | 92ea9772e8e0169a1a97af78a04de9f39eb29c13 /weed/topology/configuration.go | |
| parent | 98d66a569b0b1ee1ef0b58fbf3bd0fa2fc917f5d (diff) | |
| download | seaweedfs-41f686ab9d8aaa94dc6e8c6746ecd7f63bc98506.tar.xz seaweedfs-41f686ab9d8aaa94dc6e8c6746ecd7f63bc98506.zip | |
remove weeds.conf
Diffstat (limited to 'weed/topology/configuration.go')
| -rw-r--r-- | weed/topology/configuration.go | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/weed/topology/configuration.go b/weed/topology/configuration.go index ffcebb59c..2a544ce1d 100644 --- a/weed/topology/configuration.go +++ b/weed/topology/configuration.go @@ -25,20 +25,6 @@ type Configuration struct { ip2location map[string]loc } -func NewConfiguration(b []byte) (*Configuration, error) { - c := &Configuration{} - err := xml.Unmarshal(b, c) - c.ip2location = make(map[string]loc) - for _, dc := range c.Topo.DataCenters { - for _, rack := range dc.Racks { - for _, ip := range rack.Ips { - c.ip2location[ip] = loc{dcName: dc.Name, rackName: rack.Name} - } - } - } - return c, err -} - func (c *Configuration) String() string { if b, e := xml.MarshalIndent(c, " ", " "); e == nil { return string(b) |
