From 5b622f5d23e4e074b2e1a70f765c8a1460d398d8 Mon Sep 17 00:00:00 2001 From: Xavier Zhao Date: Wed, 3 Feb 2021 10:19:38 +0800 Subject: [PATCH] update: async dial in client of k8s example to prevent panic if servers start after the client. --- examples/k8s/client/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/k8s/client/main.go b/examples/k8s/client/main.go index ca8e47c..75c22e1 100644 --- a/examples/k8s/client/main.go +++ b/examples/k8s/client/main.go @@ -19,7 +19,7 @@ func init() { resolver.Register(discov.NewBuilder(discov.WithDNSPollingInterval(time.Second))) - greetingClientConn, err := grpc.Dial("discov://dns/greeting-svc:8080", grpc.WithBlock(), grpc.WithInsecure()) + greetingClientConn, err := grpc.Dial("discov://dns/greeting-svc:8080", grpc.WithInsecure()) if err != nil { panic(err) }