Add destination address to debug log
This commit is contained in:
parent
d5ff301d90
commit
ec25bdb9f9
2 changed files with 2 additions and 2 deletions
|
@ -48,7 +48,7 @@ func NewProxy(address string, terminationDelay time.Duration, proxyProtocol *dyn
|
||||||
|
|
||||||
// ServeTCP forwards the connection to a service.
|
// ServeTCP forwards the connection to a service.
|
||||||
func (p *Proxy) ServeTCP(conn WriteCloser) {
|
func (p *Proxy) ServeTCP(conn WriteCloser) {
|
||||||
log.WithoutContext().Debugf("Handling connection from %s", conn.RemoteAddr())
|
log.WithoutContext().Debugf("Handling connection from %s to %s", conn.RemoteAddr(), p.address)
|
||||||
|
|
||||||
// needed because of e.g. server.trackedConnection
|
// needed because of e.g. server.trackedConnection
|
||||||
defer conn.Close()
|
defer conn.Close()
|
||||||
|
|
|
@ -20,7 +20,7 @@ func NewProxy(address string) (*Proxy, error) {
|
||||||
|
|
||||||
// ServeUDP implements the Handler interface.
|
// ServeUDP implements the Handler interface.
|
||||||
func (p *Proxy) ServeUDP(conn *Conn) {
|
func (p *Proxy) ServeUDP(conn *Conn) {
|
||||||
log.WithoutContext().Debugf("Handling connection from %s", conn.rAddr)
|
log.WithoutContext().Debugf("Handling connection from %s to %s", conn.rAddr, p.target)
|
||||||
|
|
||||||
// needed because of e.g. server.trackedConnection
|
// needed because of e.g. server.trackedConnection
|
||||||
defer conn.Close()
|
defer conn.Close()
|
||||||
|
|
Loading…
Reference in a new issue