r/java • • Feb 14 '22

Microhttp is an event-driven, single-threaded, zero-dependency web server with 500 LOC. Benchmarks on EC2 show 100,000+ requests per second and 50,000+ persistent connections.

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

107 comments sorted by

View all comments

Show parent comments

8

u/crummy Feb 14 '22

do people actually do TLS in their Java webservers? i.e. they aren't behind nginx, caddy etc?

5

u/elliotbarlas Feb 14 '22

Not in my experience. A perfect example of a reasonable feature in a comprehensive, general purpose web server that just isn't used in practice.

7

u/stringbet Feb 14 '22

Eh.. there are reasons to do it. When you're handling 1m requests/s, putting the SSL on your LB is a significant CPU burden which makes scaling harder. Pushing SSL back to your server pool allows the LB to operate in Layer 4 and thus it can handle a lot more traffic.

2

u/lambdacats Feb 15 '22

Yes, for security i prefer this approach as well.