forward

package
v0.7.4 Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2020 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewForwardWithConfig

func NewForwardWithConfig(conf *Config) (http.Handler, error)

NewForwardWithConfig create a new forward with config.

Types

type Config

type Config struct {
	H2c    bool          `json:",omitempty"`
	Dialer stream.Dialer `json:",omitempty"`
	URL    string
}

type Forward

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

func NewForward

func NewForward(url string, dialer stream.Dialer, h2c bool) (*Forward, error)

func (*Forward) ServeHTTP

func (h *Forward) ServeHTTP(rw http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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