Async on linux

Instructor: Martin Mosler

Asynchronous programming is a valuable skill for any Rust developer, enabling them to build high-performance, concurrent applications that are both efficient and maintainable. Async Rust promises benefits including improved performance, safety and scalability, along with a more ergonomic and enjoyable development experience. However, there are also some pitfalls, like blocking and cancellation issues, that can happen when developing async code. We will also look the these issues and how to avoid them.

In this hands-on workshop, we develop a concurrent communication application using the async programming paradigm in order to practice its syntax and control flow. We will also look at common problems that might occur and learn how to solve them.

Prerequisites / target audience

This workshop is designed for developers who are already working on Rust codebases without concurrency and want to dive into async programming.

Topics

  1. Introduction/Refresher of Async Programming

    • Overview of async programming
    • Comparison with multithreading
    • Benefits and use cases of async programming
  2. Async Programming Concepts

    • Introduction to async/await syntax
    • Understanding Futures and how they work
    • Overview of Runtimes and Tasks in async programming
    • Using Channels for communication between tasks
    • Managing control flow with Join and Select operations
  3. Implementation of Async Programming

    • Practical example project for hands-on experience
    • Coding exercises to practice writing async code
    • Common pitfalls in async programming
  4. Advanced Topics in Async Programming

    • Exploring the internals of async programming
    • Understanding how async code is executed by the executor
    • Discussing best practices for writing efficient and readable async code
  5. Pitfalls and Troubleshooting

    • Addressing common challenges faced while working with async code
    • Tips for dealing with blocking issues, handling async traits, and managing cancellation in async programming

Technological prerequisites

A working rust toolchain along with the editor of your choice. Look at rustup.rs on how to set it up.


Martin Mosler

For location and schedule visit our Workshops page