
Launch goroutines as lightweight threads that run concurrently under the Go runtime. See how asynchronous tasks execute, with non-deterministic order, and use brief sleeps to observe concurrency.
Learn how a mutex from the sync package guards a critical section in Go concurrency, preventing data races as many goroutines safely increment a shared count one at a time.
Learn how to coordinate goroutines in Go using a condition variable and mutex, with a producer-consumer example that uses wait and signal to manage a shared counter.
Demonstrates using Go's wait groups from the sync package to coordinate goroutines, compare with mutex and condition variables, and show two clear patterns for signaling completion.
Explore atomic operations in Go to achieve low-level synchronization by replacing mutexes in simple increments and reads, preventing data races across 1,000 goroutines, and safely updating complex values with atomic.Value.
Reuse objects with Go's pool to reduce memory usage and garbage collection. Use get and put with a new function for safe concurrent access by goroutines to database connections.
Explore how channels enable communication and synchronization between goroutines in Go, including unbuffered and buffered channels, send and receive operations, and multiple goroutines sharing channels.
Explore how the Go select statement multiplexes goroutine communication by waiting for multiple channels, forwarding messages to matching cases, and ensuring only one case executes at a time.
Explore how this class guides you through building a Go web crawler that uses goroutines, channels, mutexes, waitgroups, and atomic statistics to handle http requests.
Learn how the Go data race detector identifies concurrent reads and writes to shared data using the -race flag, and see how mutexes and atomic operations resolve races.
Explore how the context package manages goroutine lifecycles in Go, using with cancel, with timeout, with deadline, and with value for hierarchical context propagation.
Celebrate completing the course and apply the gained insights on concurrent programming with Go to your projects, stay curious, and keep coding.
Unlock the potential of concurrent programming in Go with this guide. Designed for intermediate and advanced developers, this hands-on course equips you with the skills needed to create efficient, responsive, and scalable software solutions.
Dive into the world of Golang concurrency as you explore the key pillars of concurrent processing: goroutines, mutexes, condition variables, wait groups, atomic operations, channels, and more.
The course takes you further, enabling you to eliminate data races and ensure data integrity across multi-threaded applications.
How you follow this course:
All classes in this course are practical. It does not mean that you won't understand the concepts, quite the contrary! Before starting coding, I introduce you to what we're going to cover, explaining the language concepts and showing diagrams. Only after this we code.
Each class has its own code snipped attached to it, if you don't want to code along with the course, you can download the snippet and follow from there.
We also have a quiz in the end of each class, so you can test yourself and make sure you understood what was covered. It's not mandatory, as also the review class, but I highly recomend you to go through it.
Hope you enjoy it.