[development] don't abuse variabes as storage system

Moshe Weitzman weitzman at tejasa.com
Fri May 4 14:17:59 UTC 2007


we tried this and Dries was not amenable at the time. Maybe a few more 
opinions and modifications would help. See http://drupal.org/node/79008

> Yeah, that's a major nuissance. Can't we add a "no cache" bit to the
> variables table? Variables marked such, would not get added to the
> cached version (and bloat it) but would be retrieved from the table each
> time when needed. This would be perfectly acceptable for e.g. the
> password reminder mail templates.
> 
> I imagine it would be ok to set the value of this bit based on the
> length of the stored string. We already do something similar for the
> locale cache where we do not store strings longer than 75 chars in the
> cached version.
> 
> The result of this would be:
> 
> 1) better performance for most pages (the ones that don't require one of
> the long strings)
> 
> 2) somewhat worse performance for a few pages.
> 
> 3) no guilt trips for abusing the variable_get/set functions once more. :p



More information about the development mailing list