Socket reconnection on timeout