Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CRM-21568 - Move emptiness judgments from SettingsBag::setDb to InnoDBIndexer #11423

Merged
merged 1 commit into from
Dec 18, 2017

Commits on Dec 16, 2017

  1. CRM-21568 - Move emptiness judgments from SettingsBag::setDb to InnoD…

    …BIndexer
    
    The `SettingsBag::setDb()` function calls any `on_change` listeners.  It
    originally used "dumb on change" behavior (where it calls the listeners
    without comparing values).  CRM-19610 had an issue where the `InnoDBIndexer`
    was running a bit too often, so they tried to resolve it by
    making the `SettingsBag::setDb()` more clever.
    
    Unfortunately, that's been a bit bouncy, and the cleverness depends on one's
    particular interpretation of 0 vs '0' vs '' vs NULL vs FALSE.
    
    Before
    ------
    All on-change listeners may be skipped if there's particular mix of emptiness
    in the old/new values.
    
    After
    -----
    The on-change listeners always fire. However, the specific listener
    involved with CRM-19610 will now ignore some insignificant changes.
    
    Related discussion: civicrm#11417
    
    ----------------------------------------
    * CRM-21568:
      https://issues.civicrm.org/jira/browse/CRM-21568
    * CRM-19610:
      https://issues.civicrm.org/jira/browse/CRM-19610
    totten committed Dec 16, 2017
    Configuration menu
    Copy the full SHA
    38e5457 View commit details
    Browse the repository at this point in the history