Separate connection setup into an explicit step.