Documentation ¶
Index ¶
- func Run()
- type Config
- type Controler
- func (c *Controler) HandleCloseTunnelRequest(req *msgpb.CloseTunnelRequest) *msgpb.CloseTunnelResponse
- func (c *Controler) HandleError(err error)
- func (c *Controler) HandleNewTunnelRequest(req *msgpb.NewTunnelRequest) *msgpb.NewTunnelResponse
- func (c *Controler) HandlePingResponse(req *msgpb.PingResponse)
- func (c *Controler) HandleShutdownRequest(req *msgpb.ShutdownRequest) bool
- func (c *Controler) HandleUnknownMessage(msg interface{})
- func (c *Controler) Run() error
- type TCPProxy
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { ID string Hash string ControlServer string HeartbeatInterval time.Duration Timeout struct { GracefulShutdown time.Duration Control util.TimeoutConfig Tunnel util.TimeoutConfig Local util.TimeoutConfig } Retrier *retry.Retrier }
func (*Config) BuildRPCClientConf ¶
func (conf *Config) BuildRPCClientConf() *birpc.ClientConfig
type Controler ¶
func NewControler ¶
func (*Controler) HandleCloseTunnelRequest ¶
func (c *Controler) HandleCloseTunnelRequest(req *msgpb.CloseTunnelRequest) *msgpb.CloseTunnelResponse
func (*Controler) HandleError ¶
func (*Controler) HandleNewTunnelRequest ¶
func (c *Controler) HandleNewTunnelRequest(req *msgpb.NewTunnelRequest) *msgpb.NewTunnelResponse
func (*Controler) HandlePingResponse ¶
func (c *Controler) HandlePingResponse(req *msgpb.PingResponse)
func (*Controler) HandleShutdownRequest ¶
func (c *Controler) HandleShutdownRequest(req *msgpb.ShutdownRequest) bool
func (*Controler) HandleUnknownMessage ¶
func (c *Controler) HandleUnknownMessage(msg interface{})
type TCPProxy ¶
func NewTCPProxy ¶
func NewTCPProxy(req *msgpb.NewTunnelRequest, ctl *Controler) (*TCPProxy, error)
Click to show internal directories.
Click to hide internal directories.