Explore projects
Rustadvancedbackend
High-performance HTTP/2 Server
HTTP/2 server from scratch in Rust with TLS via rustls, stream multiplexing, flow control, and server push.
5 steps
Project steps
- 01
TLS with rustls
TcpListener + rustls TLS acceptor with certificates from file.
- 02
H2 handshake
h2 crate: server-side HTTP/2 connection setup with ALPN.
- 03
Request routing
Simple router based on path; Tower middleware stack.
- 04
Server push
Push CSS/JS associated with an HTML request before the client asks for them.
- 05
Benchmarks
hyperfine + h2load benchmark: compares with Axum/Actix on the same hardware.
Recommended resources
Ready to build this?
Fork the repo on GitHub and start building. A mentor will review your code when you open a PR.
5 steps
Tech stack
Rusttokioh2rustlstower