1 min read

Golang Concurrency with HTTP Example

Summary

I have a server running on remote. I want to simply benchmark on one API, and get the average response time of that API. So I simply wrote a few lines of a Golang programme.

I want to benchmark

Call server API concurrently(about 1000 times at once) and see how long it takes.

Why not use Apache ab?

Well, Apache HTTP server Benchmarking tool is powerful. But It is a bit complex to learn and use, I want to do it by myself.

Source codes

Github zyfdegh/iotserver-apibench

comments powered by Disqus