Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(opt *ClientOption) (*Client, error)
NewClient returns new client and error
type ClientOption ¶
type Server ¶
type Server struct { Listener net.Listener Server *grpc.Server // grpc service name Name string // contains filtered or unexported fields }
Server GRPC server struct
func NewServer ¶
func NewServer(opt *ServerOption) (*Server, error)
NewServer returns server
server,err:=gb.NewServer(opt) server.Run()
type ServerOption ¶
type ServerOption struct { // * grpc service name Name string // * grpc service port Port int // grpc service IP address IP string // etcd endpoints EtcdEndPoints []string // etcd lease Lease int64 // whether registration service is required IsRegister bool // crt or pem file CertFile string // private key file KeyFile string }
ServerOption grpc option
Click to show internal directories.
Click to hide internal directories.