tcp

package
v0.0.0-...-a53ac42 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DynamicProxy

type DynamicProxy interface {
	ListenAndServe(ctx context.Context) error
}

DynamicProxy is an interface for components that can listen for TCP connections and, after accepting them, dynamically determine whether an L7 proxy (HTTP) or L4 proxy (plain TCP, with an assumption of TLS) is most appropriate. Implementations of this interface will delegate all further connection handling to the most appropriate proxy type.

func NewDynamicProxy

func NewDynamicProxy(
	listenAddrStr string,
	l7StartProxyCallback http.L7StartProxyCallback,
	l7EndProxyCallback http.L7EndProxyCallback,
	l4StartProxyCallback l4StartProxyCallback,
	l4EndProxyCallback l4EndProxyCallback,
) (DynamicProxy, error)

NewDynamicProxy returns a DynamicProxy.

Jump to

Keyboard shortcuts

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