Closed (fixed)
Project:
Metatag
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
21 Feb 2012 at 17:48 UTC
Updated:
4 Aug 2021 at 09:37 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
eme commentedSame question for me : 30 extra queries for a single page. This is quite incredible...
May I have this issue as "normal" at least...
Comment #2
marcoka commentedfirts: it would be helpful to post the querylog.
second: this does not match the definition of a "bug", it would be a performance issue.
post more, detailed infos about that and reopen.
Comment #3
kalis1This query
SELECT 1 FROM metatag LIMIT 0, 1is repeated 30 times or more on any page.This is called from metatag_metatags_load_multiple(), because of this piece of code :
Would it be possible to handle the installation case in another way ?
Comment #4
damienmckennaI'm ok with this being marked as a bug report as it's not a terribly good way of dealing with the issue, especially on something as critical as metatag_metatags_load_multiple().
Comment #5
dave reidWe cannot remove the call otherwise it will still cause problems on install which is where we had to add it. We should static cache the function. Or figure out the root cause. But we can't just simply "remove" it.
Comment #6
damienmckenna@DaveReid: I wasn't planning to simply remove the lines, but to do something else to both avoid the original error that required this hack and the performance penalties. This is on my list to be worked on this week.
Comment #7
dave reidFor now I've added a static cache.
http://drupalcode.org/project/metatag.git/commit/a1cc45b
Comment #8
damienmckennaLets try this for size. It adds a variable during hook_enable(), which is triggered after the schema is installed.
Comment #9
damienmckennaComment #10
damienmckennaThis isn't specifically a bug.
Comment #11
damienmckennaI think this is better.
Comment #12
damienmckennaCommitted. FYI I also added a small watchdog() statement to record if the error happens.
Comment #13
damienmckennaComment #14
damienmckennaLast night saw the release of 7.x-1.0-beta1, so I'm closing all these "fixed" issues in the interest of tidying up the issue queue. Thank you all for your help getting us to this point!
Comment #15
damienmckenna