Hi,
On a site that's in development (where e.g. theme files are being moved around a lot, and in fact database contents are being copied from one development system to another with their system tables intact and hence incorrect on the new system), is there any reason *not* to call module_rebuild_cache and system_theme_data on every page (apart from performance)?
I notice that the former uses UPDATEs on the system table in the database, whereas the latter uses DELETE/INSERTs to flush out all themes before re-INSERTing them.
Cheers, J-P
My question is why would you want to or need to? I have caching and aggregation of css files both disbaled under admin>performance until I am ready to go live and have had no problems whatsoever with caching of content or template files as I am developing. A lot less risky than putting that code in and risking forgetting about it and going live with it. I would only use a call like that on a one off basis if I was having a problem in that place that I could not fix through settings and would take it out again as soon as possible. Those are the types of things you forget about, go live with and then wonder why the site is so slow.
.s
J-P Stacey wrote:
Hi,
On a site that's in development (where e.g. theme files are being moved around a lot, and in fact database contents are being copied from one development system to another with their system tables intact and hence incorrect on the new system), is there any reason *not* to call module_rebuild_cache and system_theme_data on every page (apart from performance)?
I notice that the former uses UPDATEs on the system table in the database, whereas the latter uses DELETE/INSERTs to flush out all themes before re-INSERTing them.
Cheers, J-P
sander-martijn wrote:
My question is why would you want to or need to?
We're trying to work out ways of passing databases around in a development/test/production site, so with multiple codebases and multiple databases. When you do that, you can then be developing for some time before you realise that your new database's system table is still referencing the location of the theme/module files on the production or test server. It'd be nice to make sure automatically every request that that wasn't the case, and calling those two functions is a way to do it.
content or template files as I am developing. A lot less risky than putting that code in and risking forgetting about it and going live with it.
Shouldn't be a problem: we're also running the Devel module, which is splurging every single query on every single page in the footer, and alerting us to our newer module, so it's unlikely we'll forget to turn them both off. But I take your point, so we'll put it on the project plan anyway.
Cheers, J-P