thread

package
v0.20.5 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Parallelism

func Parallelism() int

Parallelism returns the current parellism.

This defaults to the number of CPUs.

func Parallelize added in v0.20.2

func Parallelize(jobs ...func() error) error

Parallelize runs the jobs in parallel.

A max of Parallelism jobs will be run at once. Returns the combined error from the jobs.

func SetParallelism

func SetParallelism(parallelism int)

SetParallelism sets the parallelism.

If parallelism < 1, this sets the parallelism to 1.

Types

This section is empty.

Jump to

Keyboard shortcuts

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