proxy

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2019 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Proxy

type Proxy struct {
	RequestConfigProvider RequestConfigProvider
	InvokerPool           *middleware.InvokerPool
	BufferPool            sync.Pool
	ClientPool            sync.Pool
}

type Request added in v1.5.0

type Request struct {
	Config     *RequestConfig
	RequestURL url.URL
	Body       io.Reader
	Context    context.Context
}

type RequestConfig added in v1.4.0

type RequestConfig struct {
	Schema              *[]byte
	BackendURL          url.URL
	AddHeadersToContext [][]byte
}

type RequestConfigProvider added in v1.4.0

type RequestConfigProvider interface {
	GetRequestConfig(ctx context.Context) RequestConfig
}

type RequestInterface added in v1.5.0

type RequestInterface interface {
	AcceptRequest(buff *bytes.Buffer) error
	DispatchRequest(buff *bytes.Buffer) (io.ReadCloser, error)
	AcceptResponse()
	DispatchResponse()
}

type StaticRequestConfigProvider added in v1.4.0

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

func NewStaticRequestConfigProvider added in v1.5.0

func NewStaticRequestConfigProvider(config RequestConfig) *StaticRequestConfigProvider

func (*StaticRequestConfigProvider) GetRequestConfig added in v1.4.0

func (s *StaticRequestConfigProvider) GetRequestConfig(ctx context.Context) RequestConfig

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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