pool

package
v0.0.0-...-2d02f19 Latest Latest
Warning

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

Go to latest
Published: May 3, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Canceled = errors.New("Canceled")

Canceled is returned on CompletionFuture.AwaitCompletion when a CompletionFuture was canceled

Functions

This section is empty.

Types

type CompletionFuture

type CompletionFuture interface {
	AwaitCompletion(ctx context.Context) error
	Cancel(interrupt bool, err error)
}

type Executor

type Executor interface {
	io.Closer
	Start()
	Stop()
	Submit(ctx context.Context, workItemId int32, runnable Runnable) CompletionFuture
	IsRunning() bool
}

func NewDynamicExecutor

func NewDynamicExecutor(maxNumberOfWorkers, queueDepth int, _options ...options.WithOption) Executor

func NewFixedSizeExecutor

func NewFixedSizeExecutor(numberOfWorkers, queueDepth int, _options ...options.WithOption) Executor

type Runnable

type Runnable func()

Jump to

Keyboard shortcuts

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