Development

Advanced Rust Advanced - 5 days - 4800€ HT

Description

The Rust language is now essential, offering developers the productivity of a modern, high-level language combined with strict robustness guarantees and a powerful type system. This training course aims to address the advanced concepts faced by Rust developers, enabling them to design complex, reliable, and highly maintainable software.

The topics covered, drawn from real-world experience, place a strong emphasis on practical application. Throughout the week, participants will develop a comprehensive multi-threaded data analysis and extraction tool. This project will be iteratively improved to incorporate dynamic search criteria, concurrent performance, an asynchronous client/server network interface, end-to-end testing, and control via a web interface.

  • 5 days (35 hours)

  • File scanner project, iteratively improved with each practical session

  • Implementation of complex concepts: multi-threading, asynchronicity, and advanced serialization

Objectives

  • Master advanced use of the type system, fine-grained error handling, and concurrent programming paradigms in Rust
  • Design high-performance software architectures by optimally leveraging multithreading and the asynchronous (async/await) model
  • Develop a robust end-to-end project, integrating advanced testing, client/server network communication, and a web interface

Public and prerequisites

This training is designed for technical professionals looking to enhance their Rust development skills.

  • Software developers

  • System and embedded engineers

  • Code auditors and security researchers

Prior knowledge of Rust is essential: participants must be able to read Rust code and be familiar with its syntax and fundamental concepts (pattern matching, borrowing, etc.).

Experience in system or embedded development, and/or with C/C++, is a plus.

Content

Day 1

Error handling: approaches to managing fallible operations, using the Rust standard library or common crates, advantages and limitations of each approach, factors to consider, and maintainability. Panic: specific characteristics, explicit and implicit causes, idiomatic approaches to structuring code and reducing its occurrence. Optimal use of types, APIs, and idioms: common patterns (new type, builder), advantages and specificities of Rust typing for constraining program state or interface, functional APIs (combiners) for iterators/Option/Result, maintainability, performance of generated code, antipatterns, and common errors.

Day 2

Performance & multithreading: primitives and architectures of multithreaded processing, associated APIs in the standard library and in commonly used crates, tools for evaluating program performance (benchmarking and profiling), and identifying areas for improvement. These concepts are applied to the project through file scanner optimization, migrating the architecture to multithreading, and integrating statistical counters.

Day 3

Serde: concrete examples of Serde usage, configuration, and modeling to maximize its benefits. async/await: presentation of the async model, its advantages, disadvantages, specific features, and common pitfalls. Immediate practical application through the implementation of a network command/response protocol based on Serde and the development of asynchronous client/server interfaces.

Day 4

Testing: automated testing, structuring within a complex project, possible test levels (unit, integration, performance), tips for facilitating maintenance and efficiency, advanced tools (coverage measurement, snapshot testing). In-depth implementation of comprehensive integration tests validating end-to-end interactions between the scanner client and server.

Day 5

Web Development: concepts and integration of web development in Rust, applied to scanning control via the creation of a dedicated interface. Other topics (depending on time and participants' needs): conditional compilation and code build time (simple macros, procedural macros, build.rs), management, maintenance and auditing of a dependency tree, use of FFI to interact with C code, advanced use of the Clippy linter, combinator parsers and their advantages over grammar parsers (put into practice via MIME type filtering).

All the details regarding how the training is conducted are described on this page.