consul

package
v0.0.0-...-b22a322 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2016 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// MaxQPSTag gateway max qps tag
	MaxQPSTag = "GATEWAY-MAX-QPS"
	// HalfToOpenTag gateway half to open tag
	HalfToOpenTag = "GATEWAY-HALF-TO-OPEN"
	// HalfTrafficRateTag gateway half traffic rate
	HalfTrafficRateTag = "GATEWAY-HALF-TRAFFIC-RATE"
	// CloseCountTag gateway close count
	CloseCountTag = "GATEWAY-CLOSE-COUNT"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Backend

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

Backend consul backend

func NewBackend

func NewBackend(conf *conf.Conf) (*Backend, error)

NewBackend new consul backend

func (*Backend) GetClusters

func (b *Backend) GetClusters() (map[string]*model.Cluster, error)

GetClusters get clusters

func (*Backend) GetServers

func (b *Backend) GetServers(clusterName string) (map[string]*model.Server, error)

GetServers get servers by cluster

Jump to

Keyboard shortcuts

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