integration: don't nest proxies in cluster_proxy mode

This commit is contained in:
Anthony Romano 2016-09-01 15:21:52 -07:00
parent d3ecebd14e
commit 3489fa82fb

View File

@ -52,9 +52,8 @@ func newClientV3(cfg clientv3.Config) (*clientv3.Client, error) {
if err != nil {
return nil, err
}
toGRPC(c)
c.KV = clientv3.NewKVFromKVClient(grpcproxy.KvServerToKvClient(grpcproxy.NewKvProxy(c)))
c.Watcher = clientv3.NewWatchFromWatchClient(grpcproxy.WatchServerToWatchClient(grpcproxy.NewWatchProxy(c)))
rpc := toGRPC(c)
c.KV = clientv3.NewKVFromKVClient(rpc.KV)
c.Watcher = clientv3.NewWatchFromWatchClient(rpc.Watch)
return c, nil
}