web

package
v0.0.0-...-995e40d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2021 License: MIT Imports: 12 Imported by: 0

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.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL