diff --git a/pkg/common/chatrpcstart/start.go b/pkg/common/chatrpcstart/start.go index 3004a9fae..c06c33fca 100644 --- a/pkg/common/chatrpcstart/start.go +++ b/pkg/common/chatrpcstart/start.go @@ -32,7 +32,7 @@ func Start(rpcPort int, rpcRegisterName string, prometheusPort int, rpcFn func(c return errs.Wrap(err) } defer zkClient.CloseZK() - zkClient.AddOption(chatMw.TestEmpty(), chatMw.AddUserType(), mw.GrpcClient(), grpc.WithTransportCredentials(insecure.NewCredentials())) + zkClient.AddOption(chatMw.AddUserType(), mw.GrpcClient(), grpc.WithTransportCredentials(insecure.NewCredentials())) registerIP, err := network.GetRpcRegisterIP(config.Config.Rpc.RegisterIP) if err != nil { return err diff --git a/pkg/common/mw/user.go b/pkg/common/mw/user.go index 75dfb485d..53dc2adca 100644 --- a/pkg/common/mw/user.go +++ b/pkg/common/mw/user.go @@ -19,10 +19,3 @@ func AddUserType() grpc.DialOption { return invoker(ctx, method, req, reply, cc, opts...) }) } - -func TestEmpty() grpc.DialOption { - return grpc.WithChainUnaryInterceptor(func(ctx context.Context, method string, req, reply interface{}, cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error { - log.ZInfo(ctx, "test empty", "method", method) - return invoker(ctx, method, req, reply, cc, opts...) - }) -}