c-cube / tiny_httpd

Minimal HTTP server using good old threads + blocking IO, with a small request router.
https://c-cube.github.io/tiny_httpd
75 stars 11 forks source link

Added a stress test #50

Closed craff closed 1 year ago

craff commented 1 year ago

This test run N downloads of foo (50mb) simultaneously. dune runtest uses N = 15

To manually run the test you may do:

ulimit -n 2048
cd _build/default/tests
time source stress.sh ../src/bin/http_of_dir.exe 500

I used it to compare tiny_httpd and simple_httpd (they perform similarly, when using epoll) so I thought I could do a PR for tiny_httpd.

c-cube commented 1 year ago

can you add a little readme/comments in the stress.sh file, so we remember how to use this after a while has passed?

craff commented 1 year ago

Yes, I will do that. I will (if you agree) move to /dev/random for foo_50, it is a more robust test especially with zlib ? I allready did that for simple_httpd.