this is followup to Iaab5ce609c0dcf7085f5dd43efbd37eb4b88f17b
actually retry for specified number of retries instead of raising
error on first ConnectionError
Change-Id: Ibca3f568b65dfea252da4b67f6d5105ba7f1ecb1
(cherry picked from commit 47c4d56e446a49726e7145c6cbc3bb7620a431f7)
(cherry picked from commit 11526e594c7e7cef8b5a4a4220f100d76a418036)