Zephyr Devlog #1
This week I focused on getting the core of Zephyr working and making it as fast as possible.
What I built
- Core HTTP server using Hyper
- Router with support for static and dynamic routes
- Static file serving
- Plugin system
- Metrics for tracking requests
- Benchmark suite to compare Zephyr with other frameworks
Bugs I fixed
I found a few bugs while writing integration tests:
- Body size limits weren’t always enforced.
-
If-None-Matchheaders weren’t working correctly. - The rate limiter rewrote some valid configs.
These were all fixed after writing more tests.
Performance
After benchmarking, I realised the server wasn’t using all CPU cores efficiently. I rewrote the threading model so each worker had its own runtime, which increased throughput by about 45%.
Current plaintext benchmark:
| Framework | Requests/sec |
| Zephyr | 321k |
| actix-web | 314k |
| Node.js (cluster) | 266k |
I’m happy that Zephyr is now competitive with one of the fastest Rust web frameworks.
Next
- Better WebSocket support
- Streaming static files
- More realistic benchmarks (JSON, databases, uploads)
- More plugin improvements
- Benchmarking things like RAM usage too
Overall I’m really happy with how the project is progressing. The biggest lesson this week was to benchmark before assuming something is the bottleneck.
Comments 4
wow looks super good @f
thanks so much @f i appreciate the feedback a lot
cool
@layerblayerplus thx :3 !!
Sign in to join the conversation.