amanreasoned
  • Home
  • Tech
  • Series
  • Workations!
  • About

Go Concurrency: Sync package

Tech > Go Concurrency: Sync package

Go Concurrency 1.3 - Sync Package | Channels & Select

In this post I talk about the type Channels and Select available under the sync package. While Channels can be used for both communication between concurrent processes, they can also be used in synchronisation by sharing the memory address. Select allows you to pseudo-randomly resolve one of the available/ready case.
Published on Tue, August 1, 2023
Tech > Go Concurrency: Sync package

Go Concurrency 1.2 - Sync Package | Once & Pool

Continuing the sync package series, in this post I talk about the type sync.Once and sync.Pool available under the sync package. While sync.Once offers a once.Do(func() {}) signature that is perfect for initialising most of the clients in your application. While sync.Pool{New: func() interface{}}, lets you do things like warming up, managing and creation of pool of resources.
Published on Mon, July 24, 2023
Tech > Go Concurrency: Sync package

Go Concurrency 1.1 - Sync Package | WaitGroup & Mutex

Memory access synchronisation is one of the popular ways to achieve concurrency in various languages. Sync package is one of the major difference between these languages and Go. The package provides you new set of concurrency primitives with wide abilities on top of the memory access synchronisation primitives. I am going to briefly talk about some commonly used tools from this package.
Published on Mon, July 17, 2023
© amanreasoned 2024