fix fatal error when registering node

Signed-off-by: Chanwit Kaewkasi <chanwit@gmail.com>
This commit is contained in:
Chanwit Kaewkasi 2015-01-27 15:32:28 +07:00
parent b99bcb0ee1
commit f5d3efa53e
1 changed files with 1 additions and 1 deletions

View File

@ -124,7 +124,7 @@ func (s *ZkDiscoveryService) Watch(callback discovery.WatchCallback) {
} }
func (s *ZkDiscoveryService) Register(addr string) error { func (s *ZkDiscoveryService) Register(addr string) error {
nodePath := "/" + path.Join(s.fullpath(), addr) nodePath := path.Join(s.fullpath(), addr)
// check existing for the parent path first // check existing for the parent path first
exist, _, err := s.conn.Exists(s.fullpath()) exist, _, err := s.conn.Exists(s.fullpath())