Final Project: Building a Multithreaded Web Server
For our final project, we’ll make a web server that says “hello” and looks like Figure 20-1 in a web browser.
Figure 20-1: Our final shared project
- Learn a bit about TCP and HTTP.
- Parse a small number of HTTP requests.
- Improve the throughput of our server with a thread pool.
But before we get started, we should mention one detail: the method we’ll use won’t be the best way to build a web server with Rust. A number of production-ready crates are available on that provide more complete web server and thread pool implementations than we’ll build.