interceptor

package
v0.0.0-...-8089d80 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ListenHTTPWithProxy

func ListenHTTPWithProxy(proxyServer Proxy, proxyAddressURL url.URL, listenAddress string, errorCh *chan error)

func NewProxyHandler

func NewProxyHandler(toUrl url.URL) *httputil.ReverseProxy

Types

type Proxy

type Proxy interface {
	ListenAndServe(addr string, handler http.HandlerFunc) error
}

type ServerProxy

type ServerProxy struct {
}

func (*ServerProxy) ListenAndServe

func (s *ServerProxy) ListenAndServe(addr string, handler http.HandlerFunc) error

type TestProxy

type TestProxy struct {
	Addr    string
	Handler http.HandlerFunc
}

func (*TestProxy) ListenAndServe

func (t *TestProxy) ListenAndServe(addr string, handler http.HandlerFunc) error

type TransportLogger

type TransportLogger struct{}

func (TransportLogger) RoundTrip

func (TransportLogger) RoundTrip(req *http.Request) (*http.Response, error)

Jump to

Keyboard shortcuts

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