server

package
v0.0.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ShutdownServer

func ShutdownServer(ctx context.Context)

func StartServer

func StartServer(ctx context.Context, routeLoader RouteLoader)

Types

type DeleteRouteFunc

type DeleteRouteFunc func(*weaver.ACL) error

type RouteLoader

type RouteLoader interface {
	BootstrapRoutes(context.Context, UpsertRouteFunc) error
	WatchRoutes(context.Context, UpsertRouteFunc, DeleteRouteFunc)
}

type Router

type Router struct {
	route.Router
	// contains filtered or unexported fields
}

func NewRouter

func NewRouter(loader RouteLoader) *Router

func (*Router) BootstrapRoutes

func (router *Router) BootstrapRoutes(ctx context.Context) error

func (*Router) Route

func (router *Router) Route(req *http.Request) (*weaver.ACL, error)

func (*Router) WatchRouteUpdates

func (router *Router) WatchRouteUpdates(routeSyncCtx context.Context)

type UpsertRouteFunc

type UpsertRouteFunc func(*weaver.ACL) error

type Weaver

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

Jump to

Keyboard shortcuts

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