fixes bug 916886 - retry on ConnectionError on middleware

@rhelmer r?

cc @AdrianGaudebert 

This means that when the webhead is unable to connect to the middleware it gets 10 attempts spread across 30 seconds to retry.