serverapi

package
v4.0.4 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RedirectorHeader    = "PD-Redirector"
	AllowFollowerHandle = "PD-Allow-follower-handle"
	FollowerHandle      = "PD-Follwer-handle"
)

HTTP headers.

Variables

This section is empty.

Functions

func IsServiceAllowed

func IsServiceAllowed(s *server.Server, group server.ServiceGroup) bool

IsServiceAllowed checks the service through the path.

func NewCustomReverseProxies

func NewCustomReverseProxies(dialClient *http.Client, urls []url.URL) http.Handler

NewCustomReverseProxies returns the custom reverse proxies.

func NewRedirector

func NewRedirector(s *server.Server) negroni.Handler

NewRedirector redirects request to the leader if needs to be handled in the leader.

func NewRuntimeServiceValidator

func NewRuntimeServiceValidator(s *server.Server, group server.ServiceGroup) negroni.Handler

NewRuntimeServiceValidator checks if the path is invalid.

Types

This section is empty.

Jump to

Keyboard shortcuts

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