Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/devraymondsh/rust-webframeworks-benchmark
In this project we benchmark different Rust web frameworks to see which framework can handle more requests/second.
https://github.com/devraymondsh/rust-webframeworks-benchmark
api benchmark framwork http http-server rust web
Last synced: about 1 month ago
JSON representation
In this project we benchmark different Rust web frameworks to see which framework can handle more requests/second.
- Host: GitHub
- URL: https://github.com/devraymondsh/rust-webframeworks-benchmark
- Owner: devraymondsh
- License: mit
- Created: 2023-02-12T16:18:42.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-12-29T18:39:56.000Z (about 1 year ago)
- Last Synced: 2024-10-16T10:32:40.148Z (3 months ago)
- Topics: api, benchmark, framwork, http, http-server, rust, web
- Language: HTML
- Homepage:
- Size: 430 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Rust web frameworks benchmark
In this project we benchmark different Rust web frameworks to see which framework can handle more requests/second. We have a 512kb HTML file that each candidate should serve the directory in which the file is. The gap between these frameworks are not much and may change based on the hardware and after time with newer framework updates.
### Benchmarks on Intel core i5 12400:
| Name | Version | Requests/sec | Transfer/sec |
|:------:|:----------:|:------------:|:------------:|
| Warp | 0.3.6 | 8809.19 | 4.30GB |
| Hyper | 1.1.0 | 8699.47 | 4.25GB |
| Axum | 0.7.2 | 8663.31 | 4.23GB |
| Gotham | 0.7.2 | 8613.04 | 4.21GB |
| Actix | 4.4.1 | 7617.35 | 3.72GB |
| Rocket | 0.5.0 | 6595.12 | 3.22GB |
| Salvo | 0.63.1 | 6233.79 | 3.04GB |### Enter the following command to build:
```bash
docker build -t devraymondsh/rust-webframeworks-benchmark .
```
### Enter the following command to run:
```bash
docker run -it devraymondsh/rust-webframeworks-benchmark
```
### Enter the following command to run with custom options:
```bash
docker run -e="RATE=50000" -e="THREADS=8" -e="CLIENTS=200" -e="DURATION=10" -it devraymondsh/rust-webframeworks-benchmark
```
Feel free to replace values with your own desire.