In acquia_agent_watchdog(), if a log is from cron being stuck or running over itself, acquia_agent_check_subscription() is called which in turn makes a variable_set call. If this occurs too frequently, then this can cause a constant loss of the variables cache, significantly impacting preformance.

Comments

Josh Waihi’s picture

This occurs when cron is stuck or is re-attempted while already running. This is a big problem when both occur and poormans cron is trying to run cron on every page request.

coltrane’s picture

I can see how this can be an issue for a site, but a fix will need some planning and testing. Using the variable system is standard so I hesitate to introduce a new mechanism. Instead, could the site alter the way it's running Drupal cron? Is there no (non poormanscron) regular system cron job? What's causing cron to hang?

Josh Waihi’s picture

Hi Ben,
Certainly there was an immediate work around by removing poormans cron. However I disagree that using the Variables system in this way is standard. It is certainly not designed for this style of usage though I agree it is commonly used. The Variables system is designed to set admin config options set manually via an admin UI interface. The Variables cache design is dependant on this as it assumes that the cache does not need to be rebuilt regularly. However when an automated system sets a variable it opens the Variables cache to be rebuilt far to regularly where bugs like this occur.

I'd argue that where a value can be systematically determined without user input, the value can be stored directly in cache (with cache_set) with low risk as removing this value from cache will only force the system to determine the value again. For automated values, this, IMO, should be a standard approach.

Dane Powell’s picture

Status: Active » Closed (won't fix)

This branch of Acquia Connector is no longer supported, per the version policy on the project homepage. As such, I'm tentatively closing this issue.

If this issue still applies to a supported branch (currently 7.x-3.x, 8.x-1.x, or 8.x-2.x), please reopen and select the new target version. Thanks!