Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // HopHeaders are meaningful only for a single transport-level connection, and are not stored by caches or forwarded by proxies. HopHeaders = []string{ "Connection", "Keep-Alive", "Proxy-Authenticate", "Proxy-Authorization", "Proxy-Connection", "Te", "Trailers", "Transfer-Encoding", "Upgrade", } )
Functions ¶
Types ¶
type Proxy ¶
Proxy define the IP address value, http.Transport and other additional options.
func (*Proxy) New ¶
New define HTTP client & request of http.Request itself.
also removes Hop-by-hop headers when it is sent to backend (see http://www.w3.org/Protocols/rfc2616/rfc2616-sec13.html), then add X-Forwarded-For header value with the IP address value of rotator proxy IP.
Click to show internal directories.
Click to hide internal directories.