Documentation ¶
Index ¶
- func NewClientImpl() interfaces.IRPCClientImpl
- func NewServerImpl() interfaces.IRPCServerImpl
- func UseGRPC()
- func Visit()
- type GRPCClientImpl
- type GRPCServer
- func (self *GRPCServer) Init(node interfaces.IRPCNode)
- func (self *GRPCServer) PullAcks(ctx context.Context, in *protos.PullAckRequest) (*protos.RPCAcks, error)
- func (self *GRPCServer) RPC(c context.Context, in *protos.RPCRequest) (*protos.RPCReply, error)
- func (self *GRPCServer) Start(port string)
- func (self *GRPCServer) Stop()
- type GRPCServerImpl
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewClientImpl ¶
func NewClientImpl() interfaces.IRPCClientImpl
func NewServerImpl ¶
func NewServerImpl() interfaces.IRPCServerImpl
Types ¶
type GRPCClientImpl ¶
type GRPCClientImpl struct { MailBox interfaces.IMailBox // contains filtered or unexported fields }
grpc实现
func (*GRPCClientImpl) CallRPC ¶
func (self *GRPCClientImpl) CallRPC(req *common.Request)
func (*GRPCClientImpl) Close ¶
func (self *GRPCClientImpl) Close()
func (*GRPCClientImpl) Connect ¶
func (self *GRPCClientImpl) Connect(address string)
func (*GRPCClientImpl) IsConnected ¶
func (self *GRPCClientImpl) IsConnected() bool
func (*GRPCClientImpl) ReqPullAcks ¶
func (self *GRPCClientImpl) ReqPullAcks()
func (*GRPCClientImpl) SetMailBox ¶
func (self *GRPCClientImpl) SetMailBox(i interfaces.IMailBox)
type GRPCServer ¶
type GRPCServer struct { protos.UnimplementedRPCServerServer // contains filtered or unexported fields }
响应RPC
转接到api
响应拉取返回结果
func NewGRPCServer ¶
func NewGRPCServer() *GRPCServer
func (*GRPCServer) Init ¶
func (self *GRPCServer) Init(node interfaces.IRPCNode)
func (*GRPCServer) PullAcks ¶
func (self *GRPCServer) PullAcks(ctx context.Context, in *protos.PullAckRequest) (*protos.RPCAcks, error)
func (*GRPCServer) RPC ¶
func (self *GRPCServer) RPC(c context.Context, in *protos.RPCRequest) (*protos.RPCReply, error)
func (*GRPCServer) Start ¶
func (self *GRPCServer) Start(port string)
func (*GRPCServer) Stop ¶
func (self *GRPCServer) Stop()
type GRPCServerImpl ¶
type GRPCServerImpl struct {
// contains filtered or unexported fields
}
grpc实现
func (*GRPCServerImpl) Init ¶
func (self *GRPCServerImpl) Init(n interfaces.IRPCNode)
func (*GRPCServerImpl) Start ¶
func (self *GRPCServerImpl) Start(listenAddress string)
func (*GRPCServerImpl) Stop ¶
func (self *GRPCServerImpl) Stop()
Click to show internal directories.
Click to hide internal directories.