/** * This is called by CPS_Connection whenever there is a new request to be sent. This method should not be used directly. * @ignore * @param CPS_Request &$request the request before being rendered */ public function newRequest(CPS_Request &$request) { if (!array_search(strtolower($request->getCommand()), $this->_non_retry_cmds)) { $this->_retryRequests = true; } else { $this->_retryRequests = false; } if ($this->_numUsed == count($this->_connectionStrings)) { // reset state if there's nowhere to send to $this->_usedConnections = array(); $this->_numUsed = 0; $this->_lastReturnedIndex = -1; $this->_lastSuccess = false; } }