Active
Project:
Printer, email and PDF versions
Version:
7.x-1.2
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
6 Mar 2013 at 08:41 UTC
Updated:
28 Feb 2014 at 15:26 UTC
Jump to comment: Most recent
hooks "print_node_load" and "print_mail_node_load" generating too many sql queries.
i.e. i have a "custom page" with 20+ nodes, witch displaing as node_teaser or themed(node->feields),
some of them load another nodes by hierarchy.
hooks "print_node_load" and "print_mail_node_load" generating 615 sql queries and they have taken about 400ms page loading time. it's only "front page", on catalog page i load 300+ node teasers.
We must to add any condition to check "realy we need to execute a query for this node", or change "print_node_load & print_mail_node_load" to "print_node_view & print_mail_node_view" and check by node->view_type.
Comments
Comment #1
simon georges commentedCould eventually be considered as a bug, if it's a real hit on performance.
Comment #2
thinkdrupal commentedIt is a performance issue. Any unnecessary calls to the dbase is a performance issue. It will only get worse over time.
For me as a temp workaround for my home page, i'm adding logic to check if front page before allowing the sql request. Nothing on my front page will be printable. Unfortunately, I will have to hack this module.