pool

package
v1.3.1 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2026 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Result

type Result[T any] struct {
	Value T
	// contains filtered or unexported fields
}

func NewResult

func NewResult[T any](key uuid.UUID, value T) *Result[T]

func (*Result[T]) ID

func (r *Result[T]) ID() string

type WorkerPool

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

func NewWorkerPool

func NewWorkerPool(workers int, tracer tracing.TracingInterface, monitor monitoring.MonitorInterface, logger logging.LoggerInterface) *WorkerPool

func (*WorkerPool) Stop

func (p *WorkerPool) Stop()

func (*WorkerPool) Submit

func (p *WorkerPool) Submit(command any, results chan *Result[any], wg *sync.WaitGroup) (string, error)

type WorkerPoolInterface

type WorkerPoolInterface interface {
	Submit(any, chan *Result[any], *sync.WaitGroup) (string, error)
}

Jump to

Keyboard shortcuts

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