Versions in this module Expand all Collapse all v1 v1.0.0 Jan 15, 2018 Changes in this version + const MAX_HEADER_SIZE + const MaxTicks + func HttpHostHeader(br *bufio.Reader) string + func Proxy(to BufferedConn, from BufferedConn) <-chan bool + func Sniff(conn net.Conn, readTimeout time.Duration) (net.Conn, string, error) + type BufferedConn struct + Reader *bufio.Reader + func NewBufferedConn(c net.Conn) BufferedConn + func (b BufferedConn) Peek(n int) ([]byte, error) + func (b BufferedConn) Read(p []byte) (int, error) + type Cluster struct + Key string + RouterHosts map[string]*RouterHost + Routes map[string]Route + func NewCluster(key string, routes map[string]Route) *Cluster + func (c *Cluster) Stop() + type ClusterUpdate struct + RouterHosts map[string]RouterHost + Routes map[string]Route + type Conn struct + func (c Conn) Read(b []byte) (n int, err error) + type Context struct + Conn BufferedConn + HTTPS bool + Hostname string + type GlobalStats struct + HealthyHosts []int + Hosts map[string]RouterHostWithStats + Mutation string + OverallConnections []uint + Ticks []string + UnhealthyHosts []int + type HealthCheck struct + func NewHealthCheck(routerHost *RouterHost, checkPort int, status chan HealthCheckResult, ...) *HealthCheck + func (hc *HealthCheck) Start() + func (hc *HealthCheck) Stop() + type HealthCheckResult struct + Healthy bool + RouterHost *RouterHost + type HostStats struct + ActiveConnections uint + Healthy bool + RefusedConnections uint64 + TotalConnections int64 + type ReadWriteCount struct + CountRead uint + CountWrite uint + func (rwc ReadWriteCount) IsZero() bool + type Route struct + URL string + Weight int + type RouterHost struct + ClusterKey string + HTTPPort int + HTTPSPort int + HostIP string + LastState HostStats + Name string + func NewRouterHost(name string, ip string, httpPort int, httpsPort int, s chan HealthCheckResult, ...) *RouterHost + func (rh *RouterHost) Start() + func (rh *RouterHost) Stop() + type RouterHostWithStats struct + ClusterKey string + HTTPPort int + HTTPSPort int + HostIP string + Stats []HostStats v1.0.0-SNAPSHOT Jan 8, 2018