Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ragokan/bunicorn-benchmark
https://github.com/ragokan/bunicorn-benchmark
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/ragokan/bunicorn-benchmark
- Owner: ragokan
- Created: 2023-10-19T18:42:32.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-10-24T12:22:03.000Z (about 1 year ago)
- Last Synced: 2024-05-30T16:41:48.110Z (7 months ago)
- Language: TypeScript
- Size: 60.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Benchmark
Benchmarking Bun, Node and Deno [frameworks](/src) performance, in requests per second.
You can see the details results [here](/results/index.md).
I recommend testing this by yourself as performance may varies on different machine.
## Requirements
All tool required to set up and run the benchmark.
### Bun
Bun is required to run Bun frameworks and benchmark scripts. See [bun.sh](https://bun.sh).
### Bombardier
Go is required to install the `bombardier` CLI. See [go.dev](https://go.dev).
Install `bombardier` using:```bash
# Install the CLI without a `go.mod` file
go install -mod=mod github.com/codesenberg/bombardier# Check after install
bombardier --version
```You need to manually set `GO_PATH` to your extracted `go` directory, `GO_BIN` to `$GO_PATH/bin` and add `GO_BIN` to `PATH` if `bombardier --version` fails.
## Start
Clone this reposity. Go to the root directory and run:
```bash
# Install required dependencies
bun ins# Run the benchmark
bun bench# Or do both
bun start
```## Configurations
See [configuration file](/config.ts) and the [type declarations](/lib/types.ts).
## Results
### Chart
![Chart](/results/chart.png)
### Table
| Name | Average | GET `/` | GET `/id/77?name=yzN` | GET `/api/js` | POST `/api/json` |
| :---------------------------------------: | :------: | :------: | :-------------------: | :-----------: | :--------------: |
| [Bunicorn 0.0.18](/results/main/Bunicorn) | 79204.25 | 76982.94 | 81068.13 | 81378.43 | 77387.51 |
| [Hono 3.7.2](/results/main/Hono) | 76710.43 | 75398.62 | 79552.49 | 79567.03 | 72323.60 |
| [Elysia 0.7.15](/results/main/Elysia) | 75583.11 | 75114.60 | 72507.34 | 75548.82 | 79161.67 |
| [RawBun 100.0.0](/results/main/RawBun) | 74238.77 | 73922.38 | 74951.25 | 75539.43 | 72542.04 |