Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Rust Web Programming
  • Table Of Contents Toc
Rust Web Programming

Rust Web Programming - Third Edition

By : Maxwell Flitton
4 (1)
close
close
Rust Web Programming

Rust Web Programming

4 (1)
By: Maxwell Flitton

Overview of this book

Rust is no longer just for systems programming. This book will show you why this safe and performant language is a crucial up-and-coming option for developing web applications, and get you on your way to building fully functional Rust web apps. You don’t need any experience with Rust to get started, and this new edition also comes with a shallower learning curve. You’ll get hands-on with emerging Rust web frameworks including Actix, Axum, Rocket, and Hyper. You’ll look at injecting Rust into the frontend with WebAssembly and HTTPS configuration with NGINX. Later, you’ll move on to more advanced async topics, exploring TCP and framing, and implementing async systems. As you work through the book, you’ll build a to-do application with authentication using a microservice architecture that compiles into one Rust binary, including the embedding of a frontend JavaScript application in the same binary. The application will have end-to-end atomic testing and a deployment pipeline. By the end of this book, you’ll fully understand the significance of Rust for web development. You’ll also have the confidence to build robust, functional, and scalable Rust web applications from scratch.
Table of Contents (24 chapters)
close
close
22
Other Books You May Enjoy
23
Index

Answers

  1. A thread has it's own memory and processes CPU tasks. Multiple threads can process multiple CPU computations at the same time. Async tasks have their own state and can be polled to see if they are completed or not. Async tasks are usually for non-blocking tasks such as waiting for a response from a network. Because these async tasks are non-blocking, a single thread can handle multiple async tasks, looping through and polling tasks to see if they are finished or not.
  2. We can create a non-blocking sleep future by creating a struct that has a field with the time that the struct was created, and another field for the duration of the sleep. We then implement the Future trait for the struct where the poll function gets the current time, calculates the time elapsed from the created field, and return a Ready if the duration has passed, or a Pending if the duration has not passed.
  3. A typical web service creates a TCP listener on a port in the main thread. The service then starts an...
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Rust Web Programming
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist download Download options font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon