responder

package
v1.6.3 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2019 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultTimeout = 30 * time.Second

DefaultTimeout used for shutdown

Functions

This section is empty.

Types

type Server

type Server struct {
	// contains filtered or unexported fields
}

Server wraps a minimal http server for the /hello endpoint

func NewServer

func NewServer(port int) *Server

NewServer creates a new server listening on the given port

func (*Server) Serve

func (s *Server) Serve() error

Serve http requests until shut down

func (*Server) Shutdown

func (s *Server) Shutdown() error

Shutdown server gracefully

Jump to

Keyboard shortcuts

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