Documentation
¶
Overview ¶
Package server contains the main server code, including RESP handling and high-level database operations.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Handler ¶
type Handler struct { Mux *redcon.ServeMux Server *redcon.Server // contains filtered or unexported fields }
Handler is the main server connection handler.
func NewHandler ¶
func NewHandler(version, addr, hostname, datadir string, s *serf.Serf, eventsCh chan serf.Event) (*Handler, error)
NewHandler initialized the server Handler.
func (*Handler) Register ¶
func (h *Handler) Register( command string, handler redcon.HandlerFunc, arity int, flags []string, firstKey int, lastKey int, stepKey int, categories []string, tips []string, ) *Handler
Register command into RESP handler with given handler and usage information for the command.
func (*Handler) RegisterChild ¶
func (h *Handler) RegisterChild( command string, arity int, flags []string, firstKey int, lastKey int, stepKey int, categories []string, tips []string, ) *Handler
RegisterChild registers sub-command's usage information only. Handler for parent command needs to handle the sub-command call!
Click to show internal directories.
Click to hide internal directories.