Documentation ¶
Index ¶
- func NewGrpcLoadBalanceHandler(lb load_balance.LoadBalance) grpc.StreamHandler
- func NewLoadBalanceReverseProxy(c *gin.Context, lb load_balance.LoadBalance, trans *http.Transport) *httputil.ReverseProxy
- func ReverseProxyForHttpNode()
- func ReverseProxyForHttpsNode(director func(req *http.Request), modifyFunc func(resp *http.Response) error, ...) *httputil.ReverseProxy
- type TcpReverseProxy
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewGrpcLoadBalanceHandler ¶
func NewGrpcLoadBalanceHandler(lb load_balance.LoadBalance) grpc.StreamHandler
func NewLoadBalanceReverseProxy ¶
func NewLoadBalanceReverseProxy(c *gin.Context, lb load_balance.LoadBalance, trans *http.Transport) *httputil.ReverseProxy
func ReverseProxyForHttpNode ¶
func ReverseProxyForHttpNode()
Types ¶
type TcpReverseProxy ¶
type TcpReverseProxy struct { Addr string KeepAlivePeriod time.Duration //设置 DialTimeout time.Duration //设置超时时间 DialContext func(ctx context.Context, network, address string) (net.Conn, error) OnDialError func(src net.Conn, dstDialErr error) ProxyProtocolVersion int // contains filtered or unexported fields }
TCP反向代理
func NewTcpLoadBalanceReverseProxy ¶
func NewTcpLoadBalanceReverseProxy(c *tcp_proxy_middleware.TcpSliceRouterContext, lb load_balance.LoadBalance) *TcpReverseProxy
Source Files ¶
Click to show internal directories.
Click to hide internal directories.