Golang wrapper for iperf3 C API.
iperf3
Nothing better than iperf’s developper to explain what iperf3 is:
iPerf3 is a tool for active measurements of the maximum achievable bandwidth on IP networks. It supports tuning of various parameters related to timing, buffers and protocols (TCP, UDP, SCTP with IPv4 and IPv6). For each test it reports the bandwidth, loss, and other parameters. This is a new implementation that shares no code with the original iPerf and also is not backwards compatible.
I do not develop Iperf. For more information see the ESNET page
Wrapping
iperf3 API is very powerfull, but it is in C, and I had to integrate it in a Golang service. Fortunatly, CGo enables C wrapping with Go, wonderful. The API is not fully wrapping yet, but the main functions are wrapped. This will allows you to open an iperf_test server and a client. I currently work for wrapping stream functions.
Example
Just have a look on the github repo, there is an example. Feel free to change it on your own.