sync

module
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: May 13, 2026 License: Apache-2.0

README

sync

sync provides primitives for working with collections of go routines and their associated context and error handling.

  • sync/ctxsync: context aware sync primitives.
  • sync/errgroup: simplifies common patterns of goroutine use, in particular making it straightforward to reliably wait on parallel or pipelined goroutines, exiting either when the first error is encountered or waiting for all goroutines to finish regardless of error outcome. Contexts are used to control cancelation. It is modeled on golang.org/x/sync/errgroup and other similar packages. It makes use of cloudeng.io/errors to simplify collecting multiple errors.
  • sync/syncsort: concurrency aware data sorting, including a heap.
  • sync/synctestutil: testing support, including testing for goroutine leaks.

Directories

Path Synopsis
Package ctxsync provides context aware synchronisation primitives.
Package ctxsync provides context aware synchronisation primitives.
Package errgroup simplifies common patterns of goroutine use, in particular making it straightforward to reliably wait on parallel or pipelined goroutines, exiting either when the first error is encountered or waiting for all goroutines to finish regardless of error outcome.
Package errgroup simplifies common patterns of goroutine use, in particular making it straightforward to reliably wait on parallel or pipelined goroutines, exiting either when the first error is encountered or waiting for all goroutines to finish regardless of error outcome.
Package patterns provides common synchronization and communication patterns built using channels and other primitives.
Package patterns provides common synchronization and communication patterns built using channels and other primitives.
Package syncsort provides support for synchronised sorting.
Package syncsort provides support for synchronised sorting.

Jump to

Keyboard shortcuts

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