Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ServerConfig ¶
type ServerConfig struct {
Addr string `json:"addr"`
ReadTimeoutMS int `json:"read_timeout_ms"`
ReadHeaderTimeoutMS int `json:"read_header_timeout_ms"`
WriteTimeoutMS int `json:"write_timeout_ms"`
IdleTimeoutMS int `json:"idle_timeout_ms"`
MaxHeaderBytes int `json:"max_header_bytes"`
ShutdownTimeoutMS int `json:"shutdown_timeout_ms"`
}
type SimpleServer ¶
type SimpleServer struct {
// contains filtered or unexported fields
}
func NewSimpleServer ¶
func NewSimpleServer(cfg *ServerConfig) (*SimpleServer, error)
func (*SimpleServer) Run ¶
func (s *SimpleServer) Run() error
func (*SimpleServer) SetHTTPHandler ¶
func (s *SimpleServer) SetHTTPHandler(h http.Handler)
func (*SimpleServer) Stop ¶
func (s *SimpleServer) Stop() error
Click to show internal directories.
Click to hide internal directories.