router

package
v0.0.0-...-2fc2a81 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2018 License: Apache-2.0, BSD-2-Clause-Views, BSD-3-Clause, + 1 more Imports: 33 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DrainTimeout = errors.New("router: Drain timeout")

Functions

This section is empty.

Types

type CertType

type CertType int

type RouteServiceRoundTripper

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

func (RouteServiceRoundTripper) RoundTrip

func (rc RouteServiceRoundTripper) RoundTrip(req *http.Request) (*http.Response, error)

type RouteServicesServer

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

func NewRouteServicesServer

func NewRouteServicesServer() (*RouteServicesServer, error)

func (*RouteServicesServer) ArrivedViaARouteServicesServer

func (rs *RouteServicesServer) ArrivedViaARouteServicesServer(req *http.Request) bool

func (*RouteServicesServer) GetRoundTripper

func (rs *RouteServicesServer) GetRoundTripper() RouteServiceRoundTripper

func (*RouteServicesServer) Serve

func (rs *RouteServicesServer) Serve(handler http.Handler, errChan chan error) error

func (*RouteServicesServer) Stop

func (rs *RouteServicesServer) Stop()

type Router

type Router struct {
	HeartbeatOK *int32
	// contains filtered or unexported fields
}

func NewRouter

func NewRouter(logger logger.Logger, cfg *config.Config, handler http.Handler, mbusClient *nats.Conn, r *registry.RouteRegistry,
	v varz.Varz, heartbeatOK *int32, logCounter *schema.LogCounter, errChan chan error, routeServicesServer rss) (*Router, error)

func (*Router) Drain

func (r *Router) Drain(drainWait, drainTimeout time.Duration) error

func (*Router) DrainAndStop

func (r *Router) DrainAndStop()

func (*Router) HandleConnState

func (r *Router) HandleConnState(conn net.Conn, state http.ConnState)

func (*Router) OnErrOrSignal

func (r *Router) OnErrOrSignal(signals <-chan os.Signal, errChan chan error)

func (*Router) RegisterComponent

func (r *Router) RegisterComponent()

func (*Router) Run

func (r *Router) Run(signals <-chan os.Signal, ready chan<- struct{}) error

func (*Router) ScheduleFlushApps

func (r *Router) ScheduleFlushApps()

func (*Router) Stop

func (r *Router) Stop()

Jump to

Keyboard shortcuts

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