From a957f2227bceab85a5aefaadca4e95454ce2226d Mon Sep 17 00:00:00 2001 From: wangchuxiao Date: Thu, 9 Mar 2023 15:00:32 +0800 Subject: [PATCH] script --- internal/startrpc/start.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/internal/startrpc/start.go b/internal/startrpc/start.go index fcf48bf0d..a7378ae65 100644 --- a/internal/startrpc/start.go +++ b/internal/startrpc/start.go @@ -13,6 +13,7 @@ import ( "github.com/OpenIMSDK/openKeeper" grpcPrometheus "github.com/grpc-ecosystem/go-grpc-prometheus" "google.golang.org/grpc" + "google.golang.org/grpc/credentials/insecure" "net" ) @@ -47,7 +48,7 @@ func Start(rpcPort int, rpcRegisterName string, prometheusPort int, rpcFn func(c } srv := grpc.NewServer(options...) defer srv.GracefulStop() - err = zkClient.Register(rpcRegisterName, registerIP, rpcPort) + err = zkClient.Register(rpcRegisterName, registerIP, rpcPort, grpc.WithTransportCredentials(insecure.NewCredentials())) if err != nil { return utils.Wrap1(err) }