reconnect when connection was lost