rename rpcx to zrpc

This commit is contained in:
kevin
2020-09-18 11:41:52 +08:00
parent 26e16107ce
commit 0b1ee79d3a
110 changed files with 154 additions and 154 deletions

View File

@@ -7,7 +7,7 @@ import (
"github.com/tal-tech/go-zero/core/logx"
"github.com/tal-tech/go-zero/core/service"
"github.com/tal-tech/go-zero/example/rpc/remote/unary"
"github.com/tal-tech/go-zero/rpcx"
"github.com/tal-tech/go-zero/zrpc"
"google.golang.org/grpc"
)
@@ -17,7 +17,7 @@ var (
)
type GreetServer struct {
*rpcx.RpcProxy
*zrpc.RpcProxy
}
func (s *GreetServer) Greet(ctx context.Context, req *unary.Request) (*unary.Response, error) {
@@ -33,7 +33,7 @@ func (s *GreetServer) Greet(ctx context.Context, req *unary.Request) (*unary.Res
func main() {
flag.Parse()
proxy := rpcx.MustNewServer(rpcx.RpcServerConf{
proxy := zrpc.MustNewServer(zrpc.RpcServerConf{
ServiceConf: service.ServiceConf{
Log: logx.LogConf{
Mode: "console",
@@ -42,7 +42,7 @@ func main() {
ListenOn: *listen,
}, func(grpcServer *grpc.Server) {
unary.RegisterGreeterServer(grpcServer, &GreetServer{
RpcProxy: rpcx.NewProxy(*server),
RpcProxy: zrpc.NewProxy(*server),
})
})
proxy.Start()