From 3c3a967b3cd9c7826ce44629239136f53a2dc427 Mon Sep 17 00:00:00 2001 From: Lisa Marie Maginnis Date: Mon, 21 Sep 2015 13:18:43 -0400 Subject: [PATCH] Removed cache rebuild from the GroupContact --- CRM/Contact/BAO/Contact.php | 6 ++++-- CRM/Contact/BAO/GroupContact.php | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/CRM/Contact/BAO/Contact.php b/CRM/Contact/BAO/Contact.php index e7050a73d8..07afc15b9f 100644 --- a/CRM/Contact/BAO/Contact.php +++ b/CRM/Contact/BAO/Contact.php @@ -438,7 +438,8 @@ class CRM_Contact_BAO_Contact extends CRM_Contact_DAO_Contact { // since resetting and // rebuilding cache could be expensive (for many contacts). We might come out with better // approach in future. - CRM_Contact_BAO_Contact_Utils::clearContactCaches($contact->id); + // HACK: Dave did this due to many donations and other requests failing due to acl_cache table locks + // CRM_Contact_BAO_Contact_Utils::clearContactCaches($contact->id); } if ($invokeHooks) { @@ -1815,7 +1816,8 @@ ORDER BY civicrm_email.is_primary DESC"; } // reset the group contact cache for this group - CRM_Contact_BAO_GroupContactCache::remove(); + // HACK: Dave disabled this on 12/09/2014 due to a crazy amount of lock wait timeouts on cache tables, causing donations to fail. + //CRM_Contact_BAO_GroupContactCache::remove(); if ($editHook) { CRM_Utils_Hook::post('edit', 'Profile', $contactID, $params); diff --git a/CRM/Contact/BAO/GroupContact.php b/CRM/Contact/BAO/GroupContact.php index f39d7559c4..85e655e15c 100644 --- a/CRM/Contact/BAO/GroupContact.php +++ b/CRM/Contact/BAO/GroupContact.php @@ -153,12 +153,14 @@ class CRM_Contact_BAO_GroupContact extends CRM_Contact_DAO_GroupContact { // also reset the acl cache $config = CRM_Core_Config::singleton(); if (!$config->doNotResetCache) { - CRM_ACL_BAO_Cache::resetCache(); + // HACK: Dave commented this out on 12/09/2014 due to lock wait timeouts on the acl cache that caused donations to fail. + //CRM_ACL_BAO_Cache::resetCache(); } // reset the group contact cache for all group(s) // if this group is being used as a smart group - CRM_Contact_BAO_GroupContactCache::remove(); + // HACK: Dave had to disable this, too! + //CRM_Contact_BAO_GroupContactCache::remove(); CRM_Utils_Hook::post('create', 'GroupContact', $groupId, $contactIds); -- 2.25.1