Removes profiling code and handles http failures by retrying.
Merge pull request #2 from saebyn/master

Removes profiling code and handles http failures by retrying.