From b26f4d8dd0686ae9954b96c00eb59f4097138254 Mon Sep 17 00:00:00 2001 From: ben-toogood Date: Wed, 1 Jul 2020 17:06:59 +0100 Subject: [PATCH] Deprecate client/selector (#1767) * client/{grpc,rpc}: depricate selector (wip) * {client,cmd}: remove client/selector * deprecate client/selector * router/static: fix lookup * config/cmd: add support for legacy static selector flag * config/cmd: add support for legacy dns selector flag --- grpc_test.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/grpc_test.go b/grpc_test.go index e82eab9..76fd665 100644 --- a/grpc_test.go +++ b/grpc_test.go @@ -11,6 +11,7 @@ import ( gcli "github.com/micro/go-micro/v2/client/grpc" "github.com/micro/go-micro/v2/errors" rmemory "github.com/micro/go-micro/v2/registry/memory" + "github.com/micro/go-micro/v2/router" "github.com/micro/go-micro/v2/server" gsrv "github.com/micro/go-micro/v2/server/grpc" tgrpc "github.com/micro/go-micro/v2/transport/grpc" @@ -110,14 +111,17 @@ func TestGRPCServer(t *testing.T) { r := rmemory.NewRegistry() b := bmemory.NewBroker() tr := tgrpc.NewTransport() + rtr := router.NewRouter(router.Registry(r)) + s := gsrv.NewServer( server.Broker(b), server.Name("foo"), server.Registry(r), server.Transport(tr), ) + c := gcli.NewClient( - client.Registry(r), + client.Router(rtr), client.Broker(b), client.Transport(tr), )