Move common code into a new _execute method.