Added reconnect on connect failure