server

package
v0.0.0-...-23b95e8 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2017 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(url string, routing []router.Route)

Run runs server with default config.

func RunWithConfig

func RunWithConfig(config Server)

RunWithConfig runs server with costom config.

Types

type Server

type Server struct {
	// labstack/echo instance
	Routing []router.Route

	// Middlewares labstack/echo middlewares
	Middlewares []echo.MiddlewareFunc

	// ShutdownTimeout is the duration before we begin force closing connections.
	ShutdownTimeout time.Duration

	// URI is server base URI
	URI string
}

Server defines the configuration for serving.

func NewConfig

func NewConfig(url string, routing []router.Route) Server

NewConfig creates a server configuration.

Jump to

Keyboard shortcuts

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