Add custom formatter for the logger

For more informative logging messages I have added my own formatter
which will be added to the logger.

Signed-off-by: Konrad Reiche <konrad.reiche@gmail.com>
Close cURL connection

I made the terrible mistake not to close the cURL connection through
curl.close() after I received the server's response. I assume that more
and more connections are built up and when I hit a limit the servers
stop to serve me any further connections. Hopefully this solves my
harvesting problem altogether.

Signed-off-by: Konrad Reiche <konrad.reiche@gmail.com>