Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BaseConf ¶
type BaseConf struct { PidFile string `mapstructure:"pid_file"` ServerID string `mapstructure:"server_id"` PprofBind []string `mapstructure:"pprof_bind"` CertPath string `mapstructure:"cert_path"` KeyPath string `mapstructure:"key_path"` MaxProc int `mapstructure:"max_process"` }
BaseConf is struct of base conf
type BucketConf ¶
type BucketConf struct { Size int `mapstructure:"size"` Channel int `mapstructure:"channel"` Room int `mapstructure:"room"` RoutineAmount uint64 `mapstructure:"routine_amount"` RoutineSize int `mapstructure:"routine_size"` BroadcastSize int `mapstructure:"broadcast_size"` }
BucketConf is struct of BucketConf
type Config ¶
type Config struct { Base *BaseConf `mapstructure:"base"` Log *log.Config `mapstructure:"log"` Websocket *WebsocketConf `mapstructure:"websocket"` Bucket *BucketConf `mapstructure:"bucket"` RPC *RPCConf `mapstructure:"rpc"` }
Config is struct of comet conf
var ( // Conf is var of conf Conf *Config )
type RPCConf ¶
type RPCConf struct { LogicAddr []Address `mapstructure:"logic_bind"` CometAddr []Address `mapstructure:"comet_bind"` }
RPCConf is struct of RPCConf
type WebsocketConf ¶
type WebsocketConf struct { Bind string `mapstructure:"port"` WriteWait time.Duration `mapstructure:"write_wait"` PongWait time.Duration `mapstructure:"pong_wait"` PingPeriod time.Duration `mapstructure:"ping_period"` MaxMessageSize int64 `mapstructure:"max_message_size"` ReadBufferSize int `mapstructure:"read_buffer_size"` WriteBufferSize int `mapstructure:"write_buffer_size"` }
WebsocketConf is struct of websocket conf
Click to show internal directories.
Click to hide internal directories.