Details

    • Type: Patch
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.1.0
    • Fix Version/s: 4.2.0
    • Component/s: None
    • Labels:

      Description

      A lot of email servers have limitations on the amount of emails that can be processed per certain period of time. Mostly the limitations are set to use format "emails/second". With its current functionality, CiviCRM can easily violate such limits when a large number of emails are sent by the application.

      We have discussed this issue in the following thread:

      http://forum.civicrm.org/index.php?topic=23177.0

      Below I am copying the patch suggested by my colleague Val:

      File: CRM/Mailing/Config.php
      -----------
      /**

      • How long (in micro seconds) should we wait in between each mail delivery? Setting this to 0 disables it.
        *
      • @var int
        */
        public $mailThrottleTime = 120000;
        -----------

      File: CRM/Admin/Form/Setting/Mail.php
      -----------
      $this->addElement('text','mailThrottleTime', ts('Mailer Throttle Time'));
      -----------

      File: templates/CRM/Admin/Form/Setting/Mail.tpl
      -----------
      <tr class="crm-mail-form-block-mailThrottleTime">
      <td class="label">{$form.mailThrottleTime.label}</td><td>{$form.mailThrottleTime.html} <br />
      <span class="description">

      {ts}

      The time to (u)sleep in between each e-mail in micro seconds. Setting this above 0 allows you to control the rate at which e-mail messages are sent to the mail server, avoiding filling up the mail queue very quickly. Set to 0 to disable.

      {/ts}

      </span></td>
      </tr>
      -----------

      File: CRM/Mailing/BAO/Job.php
      -----------
      // If we have enabled the Throttle option, this is the time to enforce it.
      $config = CRM_Core_Config::singleton();
      if($config->mailThrottleTime > 0)

      { usleep((int)$config->mailThrottleTime); }

      -----------

      We hope that you will take into consideration this patch and our concern that the current functionality of the application can cause a lot of issues to CiviCRM users.

      We are looking forward to your reply.

      Regards,

      Dave
      Siteground Technical Support Team

        Attachments

          Activity

            People

            • Assignee:
              lobo Donald A. Lobo
              Reporter:
              sgsupport Siteground Technical Support
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: