Skip to main content

Going back to Go: Concurrency Patterns

· One min read

Building blocks for concurrency in go (goroutine, channel) and patterns (fan out).

TODO

Basic

  • start (and stop) go routine
  • channel, buffer, not buffered, select

Patterns (I can think of top of my head)

  • pipeline
    • fan out (one web page has multiple links)
    • fan in, wait until multiple part download has finished
  • limit parallelism, e.g. at most two concurrent outgoing requests

Libraries

  • error group
  • single flight

Top google search results