Temporal

Parallelism and Concurrency

Aug 15, 2023
Parallelism and Concurrency
SummaryAI, from the source post

This post clarifies the fundamental concepts of concurrency and parallelism, defining them as the ability to handle multiple things in an undefined order and the ability for multiple things to run literally at the same time, respectively. It explains how these concepts apply to single-threaded environments (like JavaScript) through event loops and to multi-core/multi-machine environments. The post then details how Temporal's Workflow execution model, with its deterministic event loop, provides both concurrency and parallelism, along with fault tolerance, for distributed systems. It uses an online food ordering application as an example to illustrate how Temporal Workflows manage complex, stateful processes that benefit from these properties.

More from the Durable Execution trail