Documentation ¶
Index ¶
- type GrpcServer
- func (srv *GrpcServer) Disconnect(ctx context.Context, req *conn.DisconnectReq) (*conn.DisconnectResp, error)
- func (s *GrpcServer) GracefulStop() error
- func (srv *GrpcServer) Notify(ctx context.Context, req *conn.NotifyReq) (*conn.NotifyResp, error)
- func (s *GrpcServer) Serve(lis net.Listener) error
- func (s *GrpcServer) Stop() error
- type MQTTServer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GrpcServer ¶
type GrpcServer struct {
// contains filtered or unexported fields
}
func NewGrpcServer ¶
func NewGrpcServer(ctx *gctx.GrpcSrvContext) *GrpcServer
func (*GrpcServer) Disconnect ¶
func (srv *GrpcServer) Disconnect(ctx context.Context, req *conn.DisconnectReq) (*conn.DisconnectResp, error)
func (*GrpcServer) GracefulStop ¶
func (s *GrpcServer) GracefulStop() error
func (*GrpcServer) Notify ¶
func (srv *GrpcServer) Notify(ctx context.Context, req *conn.NotifyReq) (*conn.NotifyResp, error)
func (*GrpcServer) Stop ¶
func (s *GrpcServer) Stop() error
type MQTTServer ¶
type MQTTServer struct {
// contains filtered or unexported fields
}
MQTTServer
func NewMQTTServer ¶
func NewMQTTServer(ctx *context.MqttSrvContext) *MQTTServer
NewMQTTServer create a new mqtt server
func (*MQTTServer) GracefulStop ¶
func (s *MQTTServer) GracefulStop() error
GracefulStop first close the client connection before pushing out the program
func (*MQTTServer) Stop ¶
func (s *MQTTServer) Stop() error
Stop provide fastclose, will not send will msg
Click to show internal directories.
Click to hide internal directories.