Using Siege for quick and dirty load test — Apache Benchmark Alternative

Today, I wanted to run a quick and dirty load test on one of my applications. One of the alternative that most of the developers are aware of is Apache Benchmark(or ab). For some reason, ab does not work on my mac book because of Connection reset by peer errors. So, I looked around and found Siege. It is very similar to ab and works well on mac.

To test the GET request, you would run

siege http://example.com/rest/todos/3 -c 100 -r 100

To test the POST request, you would run

siege -H 'Content-Type:application/json' "http://example.com/rest/todos POST < ./data.json" -c 10 -r 1000