Handle connection failure in between preparing and executing