An open API service indexing awesome lists of open source software.

https://github.com/laqudee/rust_httpserver

Rust搭建的http与httpserver
https://github.com/laqudee/rust_httpserver

http http-server rust

Last synced: about 1 year ago
JSON representation

Rust搭建的http与httpserver

Awesome Lists containing this project

README

          

# Rust Http HttpServer

- Rust Server

- Rust Client
- Actix

## Web Server
- Server,监听进来的TCP字节流
- Router,接受HTTP请求,并决定调用哪个Handler
- Handler,处理HTTp请求,构建HTTP响应
- HTTP Library
- 解释字节流,把它转化为HTTP请求
- 把HTTP响应转化为字节流

- 构建步骤:
- 解析HTTP请求
- 构建HTTP请求
- 路由与Handler
- 测试Web Server

- 数据结构
- HttpRequest struct
- Method enum
- Version enum

- 三个数据结构要实现三个Trait
- From<&str>
- Debug
- PartialEq