SONARPLUGINS-2574 improve handling of connection failure