r/java • • Jul 25 '22

Latest version of Microhttp, an event-driven, zero-dependency, pure-Java web server with 500 LOC, capable of 1,000,000+ requests per second on commodity EC2 hardware.

https://github.com/ebarlas/microhttp
136 Upvotes

35 comments sorted by

View all comments

12

u/elliotbarlas Jul 25 '22

Microhttp is registered with TechEmpower Framework Benchmarks. Latest continuous run results:

2,163,060 req/sec - plaintext test
1,268,535 req/sec - JSON test
284,587 req/sec - DB query test

https://www.techempower.com/benchmarks/#section=test&runid=c72182f8-476d-4920-a264-26f615d693d3&test=plaintext

The TechEmpower benchmark repo is here:

https://github.com/TechEmpower/FrameworkBenchmarks/tree/master/frameworks/Java/microhttp

6

u/Mean-Chipmunk3255 Jul 25 '22

how come javascript framework beating java/c/c++/rust frameworks in bench marking. it is very strange.

13

u/elliotbarlas Jul 25 '22

In many cases, folks wrap native C/C++ code in a thin high-level language wrapper. So the framework language can be deceiving. That's also why I called out pure-Java. Microhttp is not one of those frameworks.