Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ClientCounter int
ClientCounter Record the number of clients in the current Godis server
Functions ¶
func ListenAndServe ¶
ListenAndServe binds port and handle requests, blocking until close ListenAndServe binds port and handle requests, blocking until close
Types ¶
type Config ¶
type Config struct { Address string `yaml:"address"` MaxConnect uint32 `yaml:"max-connect"` Timeout time.Duration `yaml:"timeout"` }
Config stores tcp server properties
type EchoClient ¶ added in v1.2.5
EchoClient is client for EchoHandler, using for test
func (*EchoClient) Close ¶ added in v1.2.5
func (c *EchoClient) Close() error
Close close connection
type EchoHandler ¶
type EchoHandler struct {
// contains filtered or unexported fields
}
EchoHandler echos received line to client, using for test
Click to show internal directories.
Click to hide internal directories.