Network Programming in Rust
286 Seiten
German
PDF
4.5

Network Programming in Rust

Практическое руководство по созданию сетевых приложений

Autor:

Jahr:

Zusammenfassung:

Introduction

The book "Network Programming with Rust" (author: Abhijit Gadgil, 2018, 286 pages) is a practical guide dedicated to building network applications in the Rust language. In an era where performance and memory safety are becoming critical factors, Rust offers a unique combination of low-level control and safety guarantees. The author aims to teach the reader not just to write network code, but to do so efficiently, using all the language's strengths: the ownership system, borrowing, lifetimes, and a powerful type system.

What the book is about

The book covers a wide range of topics — from the basics of working with sockets to building high-load asynchronous servers. It begins with an introduction to the Rust ecosystem and basic concepts of network communication (OSI model, TCP/UDP). Then it sequentially covers:

  • Working with blocking and non-blocking sockets;
  • TCP and UDP protocols, their implementation in Rust;
  • Creating HTTP servers and clients using popular crates (hyper, reqwest);
  • Asynchronous programming with tokio and async/await (at the time of the book's release — futures);
  • Security: TLS/SSL encryption, working with certificates;
  • Interaction with databases over the network (using PostgreSQL as an example);
  • Testing network applications and debugging.

Each chapter contains practical code examples that can be immediately applied.

Empfehlungen