Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrTimeout timeout exceed error. ErrTimeout = errors.New("sync: timeout exceed") )
Functions ¶
func WaitCtx ¶
func WaitCtx(ctx context.Context, defaultTimeout time.Duration, jobs ...func(ctx context.Context)) error
WaitCtx executes the given jobs in goroutines, and wait until the jobs done or context deadline exceed. DefaultTimeout will be applied if context doesn't has deadline. Error if deadline exceed.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.