Part 3: Asynchronous Programming with Promises, Futures, and Coroutines
In this part, we shift our focus to the core subject of this book, asynchronous programming, a critical aspect of building responsive, high-performance applications. We will learn how to execute tasks concurrently without blocking the main execution flow by utilizing tools such as promises, futures, packaged tasks, the std::async
function, and coroutines, a revolutionary feature enabling asynchronous programming without the overhead of creating threads. We will also cover advanced techniques for sharing futures and examine real-world scenarios where these concepts are essential. These powerful mechanisms allow us to develop efficient, scalable, and maintainable asynchronous software needed for modern software systems.
This part has the following chapters:
- Chapter 6, Promises and Futures
- Chapter 7, The Async Function
- Chapter 8, Asynchronous Programming Using Coroutines