

Coordination in Distributed Systems - Grokking Concurrency by Kirill Bobrov
May 20, 2025
Dive into concurrency as the hosts tackle mutexes, semaphores, and the reactor pattern! Discover the complexities of race conditions and synchronization while drawing parallels to creativity in engineering. Explore the significance of telemetry in the age of AI-driven code and unravel the dining philosophers problem for a fun yet insightful take on resource management. From blocking vs. non-blocking IO to the vital connection between frontend and backend roles, this discussion is packed with valuable insights for software engineers!
AI Snips
Chapters
Books
Transcript
Episode notes
Race Conditions and Deadlocks
- Race conditions occur when multiple threads access a resource simultaneously causing errors.
- Concurrency boosts performance but requires careful resource locking to avoid deadlocks and freezes.
Semaphores Optimize Concurrency
- Semaphores let you limit how many parallel workers access a resource, balancing reads and writes.
- Using semaphores for read-heavy workloads improves performance by allowing many simultaneous readers.
Using Redis for Distributed Locks
- Nathan built a web crawler using Redis keys with time-to-live to avoid deadlock in distributed locks.
- If a lock isn't released due to failure, it expires automatically, preventing system freezes.