Documentation ¶
Index ¶
Constants ¶
View Source
const MaxCloseWaitTime = 10 * time.Second
MaxCloseWaitTime is the max waiting time for closing services.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct { MaxCloseWaitTime time.Duration // max waiting time when closing server EntityMgr *entity.EntityManager // contains filtered or unexported fields }
Server is a gobbq server to serve RPC requests.
func (*Server) Close ¶
Close implements Service interface, notifying all services of server shutdown. Would wait no more than 10s.
func (*Server) ListenAndServe ¶
func (*Server) RegisterNetService ¶
func (s *Server) RegisterNetService(ns nets.NetService)
func (*Server) RegisterOnShutdown ¶
func (s *Server) RegisterOnShutdown(fn func())
RegisterOnShutdown registers a hook function that would be executed when server is shutting down.
Directories ¶
Path | Synopsis |
---|---|
cmd
|
|
components
|
|
engine
|
|
codec
Package encoding defines the interface for the compressor and codec, and functions to register and retrieve compressors and codecs.
|
Package encoding defines the interface for the compressor and codec, and functions to register and retrieve compressors and codecs. |
model
Package pbsupport protobuf support used in db package.
|
Package pbsupport protobuf support used in db package. |
example
|
|
proto
|
|
tool
|
|
secure
Package util 安全的协程和函数调用,其中协程数量不支持配置热更新.
|
Package util 安全的协程和函数调用,其中协程数量不支持配置热更新. |
Click to show internal directories.
Click to hide internal directories.