Maybe a good idea would be to try to reconnect and if it is
failing too much select another IP.
It currently does do this, but on probably a shorter time period
than you are suggesting. It keeps a count of connection failures
while trying to reconnect, but this is reset once a new connection
is established.
Yes I meant measuring a larger time period and over different
circuits as the cause of disconnection could have being the circuit
failing and not the IP.
What happens if the HS just goes offline for a while? It keeps trying
to connect, finds that it can't connect to the IPs and picks another
set? You are differentiating that case?