Documentation ¶
Index ¶
Constants ¶
View Source
const ( // TagHeaderNamePrefix indicates a Netscale Warp Tag prefix that gets appended for warp traffic stream headers. TagHeaderNamePrefix = "Cf-Warp-Tag-" LogFieldCFRay = "cfRay" LogFieldLBProbe = "lbProbe" LogFieldRule = "ingressRule" LogFieldOriginService = "originService" LogFieldFlowID = "flowID" LogFieldConnIndex = "connIndex" LogFieldDestAddr = "destAddr" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Proxy ¶
type Proxy struct {
// contains filtered or unexported fields
}
Proxy represents a means to Proxy between netscale and the origin services.
func NewOriginProxy ¶
func NewOriginProxy( ingressRules ingress.Ingress, warpRouting ingress.WarpRoutingConfig, tags []tunnelpogs.Tag, log *zerolog.Logger, ) *Proxy
NewOriginProxy returns a new instance of the Proxy struct.
func (*Proxy) ProxyHTTP ¶
func (p *Proxy) ProxyHTTP( w connection.ResponseWriter, tr *tracing.TracedHTTPRequest, isWebsocket bool, ) error
ProxyHTTP further depends on ingress rules to establish a connection with the origin service. This may be a simple roundtrip or a tcp/websocket dial depending on ingres rule setup.
func (*Proxy) ProxyTCP ¶
func (p *Proxy) ProxyTCP( ctx context.Context, rwa connection.ReadWriteAcker, req *connection.TCPRequest, ) error
ProxyTCP proxies to a TCP connection between the origin service and netscale.
Click to show internal directories.
Click to hide internal directories.