CRM-19690 - Enable FlexMailer (if present)
authorTim Otten <totten@civicrm.org>
Sat, 3 Dec 2016 03:19:20 +0000 (19:19 -0800)
committerTim Otten <totten@civicrm.org>
Tue, 3 Jan 2017 10:25:32 +0000 (02:25 -0800)
commitaa4343bcf4bf5a861c82dc35b693dea8ca324b35
tree9317b85d05a2ca5c238855fc7a6908f00becfd3a
parent041022cc7fb722c21e33f2fa244844a96538d80e
CRM-19690 - Enable FlexMailer (if present)

FlexMailer (https://github.com/civicrm/org.civicrm.flexmailer/) is a
refactoring of the email-delivery logic from the Mailing BAOs.  The primary
goal is to make the email-delivery logic more extensible by exposing a
better set of events for extension-authors.  Sadly, the original code is a
bit toxic (originally lacking in tests; thick with many features; using some
quirky dataflows), which means:

 1. Any refactoring of it poses a high risk.
 2. The refactoring should ideally be done with iteration/validation as
    an optional extension.

This patch aims to be the bare-minimum core patch required to facilitate a
better 'leap by extension'.  The main priorities are:

 1. Minimize risk -- no impact on existing users who can continue using existing logic.
 2. Enable iteration/testing/deployment of an optional extension in real-world scenarios.
 3. Keep any core hacks clear and isolated - don't rashly commit to new, public APIs.
CRM/Mailing/BAO/MailingJob.php
Civi/Core/Container.php