proxy

package module
v0.0.0-...-73c6c30 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2018 License: MIT Imports: 13 Imported by: 1

README

proxy

Fast generic tcp/udp proxy with some very nice features.

Features:

  • Generic tcp/udp proxy - if you want an http proxy get nginx or hipache
  • Metric connections for entire proxy or per backend
  • TLS client authentication for any tcp backend
  • REST API for manging backends dynamically

API:

  • GET /

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CollectStats

func CollectStats()

Types

type Backend

type Backend struct {
	Name             string `json:"name,omitempty"`
	Proto            string `json:"proto,omitempty"`
	BindIP           net.IP `json:"bind_ip,omitempty"`
	BindPort         int    `json:"bind_port,omitempty"`
	IP               net.IP `json:"backend_ip,omitempty"`
	Port             int    `json:"backend_port,omitempty"`
	MaxConcurrent    int    `json:"max_concurrent,omitempty"`
	ConnectionBuffer int    `json:"connection_buffer,omitempty"`

	// TLS client side certs
	Cert string `json:"cert,omitempty"`
	Key  string `json:"key,omitempty"`
	CA   string `json:"ca,omitempty"`
}

type Proxy

type Proxy interface {
	io.Closer
	Start() error
	Backend() *Backend
}

func New

func New(backend *Backend) (proxy Proxy, err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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