Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HTTPServer ¶
type HTTPServer struct {
// contains filtered or unexported fields
}
HTTPServer is the application http server, it contains all the services
func NewHTTPServer ¶
func NewHTTPServer(cfg conf.App, logger *log.Logger) *HTTPServer
NewHTTPServer creates a new application server with the provided configurations and root router.
func (*HTTPServer) AddService ¶
func (h *HTTPServer) AddService(path string, handler http.Handler)
AddService attaches a new Service to the root router
func (*HTTPServer) StartAndWait ¶
func (h *HTTPServer) StartAndWait(shutdownTimeout time.Duration) error
StartAndWait starts the application server and waits for a gracefull shutdown.
Click to show internal directories.
Click to hide internal directories.