Skip to content
Snippets Groups Projects
Commit e78c26d8 authored by Joe Zou's avatar Joe Zou Committed by 邹毅贤
Browse files

Merge pull request #819 from lin-jianjun/develop

Fix: etcd registry
parent e5f1ee2c
No related branches found
No related tags found
No related merge requests found
......@@ -91,7 +91,7 @@ func newETCDV3Registry(url *common.URL) (registry.Registry, error) {
r,
etcdv3.WithName(etcdv3.RegistryETCDV3Client),
etcdv3.WithTimeout(timeout),
etcdv3.WithEndpoints(url.Location),
etcdv3.WithEndpoints(strings.Split(url.Location, ",")...),
); err != nil {
return nil, err
}
......
......@@ -19,6 +19,7 @@ package etcdv3
import (
"fmt"
"strings"
"sync"
"time"
)
......@@ -313,7 +314,7 @@ func newEtcdV3ServiceDiscovery(name string) (registry.ServiceDiscovery, error) {
client := etcdv3.NewServiceDiscoveryClient(
etcdv3.WithName(etcdv3.RegistryETCDV3Client),
etcdv3.WithTimeout(timeout),
etcdv3.WithEndpoints(remoteConfig.Address),
etcdv3.WithEndpoints(strings.Split(remoteConfig.Address, ",")...),
)
descriptor := fmt.Sprintf("etcd-service-discovery[%s]", remoteConfig.Address)
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment