utils

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: Nov 2, 2021 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrDeadlineExceeded = errors.New("deadline exceeded")
)

Functions

func AwaitConnection

func AwaitConnection(dialer func() (interface{}, error), timeout time.Duration) (interface{}, error)

Types

type TimeoutRetryer

type TimeoutRetryer struct {
	DeadlineTimeout     time.Duration
	AttemptTimeout      time.Duration
	AttemptErrorHanlder func(err error)
	// contains filtered or unexported fields
}

func NewRetryer

func NewRetryer(f func() (interface{}, error), deadlineTimeout time.Duration) *TimeoutRetryer

func (*TimeoutRetryer) Do

func (r *TimeoutRetryer) Do() (interface{}, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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