workers

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2021 License: Apache-2.0 Imports: 1 Imported by: 0

README

This is a package that allows multiple goroutines doing the same task to deduplicate their work: the task gets executed once with all subscribers getting the shared result back.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Worker

type Worker interface {
	Run(id string, fn func() interface{}) (<-chan interface{}, bool)
}

func New

func New() Worker

Jump to

Keyboard shortcuts

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