Download & Extend

Detect custom cache manipulation

Project:Acquia Network Connector
Version:7.x-2.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:active

Issue Summary

Problem/Motivation

Customer has all "performance page" configuration settings correct, however they have a custom module with a hook_boot which sets $GLOBALS['conf']['cache'] = FALSE; for some visitors, killing performance. Customer in question was trying to set a cookie for first-time visitors on the back-end, with an expiration date based on the time of the first visit.

Proposed resolution

As part of the code-sniffing process, grep custom modules for this bad behavior.

Remaining tasks

Presume we'd need to find a simple regex to detect the problem with minimal number of false-positives. Something like `grep -ERI "cache['\"\]]+[ =]+FALSE" /path/to/some_custom_module`

User interface changes

N/A

API changes

None known

Comments

#1

This is a good suggestion. We don't currently do any code parsing though. We could piggyback on coder (if it's installed) to provide additional checks and send them off to Insight. We also can't assume grep is installed and shell out, unless it's a feature available only for linux-based hosts at first.