dialer

package
v0.0.0-...-b359386 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 15, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Default = net.Dialer{
	Timeout:   time.Second,
	KeepAlive: 30 * time.Second,
}
View Source
var DialAttempts = attempt.Strategy{
	Total: 30 * time.Second,
	Delay: 500 * time.Millisecond,
}
View Source
var Retry = RetryDialer{Default.Dial}

Functions

This section is empty.

Types

type DialFunc

type DialFunc func(network, addr string) (net.Conn, error)

func RetryDial

func RetryDial(dial DialFunc) DialFunc

type RetryDialer

type RetryDialer struct {
	// contains filtered or unexported fields
}

func (RetryDialer) Dial

func (r RetryDialer) Dial(network, addr string) (net.Conn, error)

func (RetryDialer) DialTimeout

func (r RetryDialer) DialTimeout(network, addr string, timeout time.Duration) (net.Conn, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL