util

package
v0.31.3 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrTimeout = errors.New("timeout exceeded")
)

Functions

func Timeout

func Timeout(f func() error, t time.Duration) error

Timeout will attempt to call f, but only for as long as t. If the function is still processing after t has elapsed then ErrTimeout will be returned.

Types

This section is empty.

Jump to

Keyboard shortcuts

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