1
0
Fork 0

Update linter

This commit is contained in:
Ludovic Fernandez 2020-05-11 12:06:07 +02:00 committed by GitHub
parent f12c27aa7c
commit 328611c619
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
157 changed files with 489 additions and 508 deletions

View file

@ -8,13 +8,13 @@ import (
"github.com/containous/traefik/v2/pkg/log"
)
// Proxy forwards a TCP request to a TCP service
// Proxy forwards a TCP request to a TCP service.
type Proxy struct {
target *net.TCPAddr
terminationDelay time.Duration
}
// NewProxy creates a new Proxy
// NewProxy creates a new Proxy.
func NewProxy(address string, terminationDelay time.Duration) (*Proxy, error) {
tcpAddr, err := net.ResolveTCPAddr("tcp", address)
if err != nil {
@ -24,7 +24,7 @@ func NewProxy(address string, terminationDelay time.Duration) (*Proxy, error) {
return &Proxy{target: tcpAddr, terminationDelay: terminationDelay}, nil
}
// ServeTCP forwards the connection to a service
// ServeTCP forwards the connection to a service.
func (p *Proxy) ServeTCP(conn WriteCloser) {
log.Debugf("Handling connection from %s", conn.RemoteAddr())