Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ReverseProxy ¶
type ReverseProxy struct {
// contains filtered or unexported fields
}
封装反向代理的基本功能
func NewReverseProxy ¶
func NewReverseProxy(targets []string, weights map[string]int) (*ReverseProxy, error)
创建反向代理实例
func (*ReverseProxy) ServeHTTP ¶
func (p *ReverseProxy) ServeHTTP(w http.ResponseWriter, r *http.Request)
实现 http.Handler 接口
Click to show internal directories.
Click to hide internal directories.