server

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 23, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {
	*gin.Engine
	Server *http.Server
	// contains filtered or unexported fields
}

func New

func New(cfg *config.ServerConfig) *Server

func (*Server) Start

func (s *Server) Start() net.Addr

start server

func (*Server) Stop

func (s *Server) Stop(ctx context.Context) error

shutdown server graceful

func (*Server) Upgrade

func (s *Server) Upgrade(ws *websocket.WebSocket) gin.IRoutes

upgrade http to websocket

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL