big sites also cause a similar problem for scratchpads_statistics -this has been disabled on the hosts scratchpad too through this PR and a variable set on the hosts.myspecies.info scratchpad
The sql generated by scratchpads_statistics that ends up making the server hang:
SELECT node.*, node.nid AS entity_id, node.vid AS revision_id, node.type AS bundle, f.field_taxonomic_name_tid AS field_taxonomic_name_tid, sst.id AS ss_term_id, ssu.id AS ss_user_id, nc.totalcount AS totalcount, nr.uid AS revision_uid, ssu_r.id AS ss_revision_user_id, 'node' AS entity_type
FROM
node node
LEFT OUTER JOIN field_data_field_taxonomic_name f ON f.entity_id = node.nid
LEFT OUTER JOIN taxonomy_term_data t ON t.tid = f.field_taxonomic_name_tid
LEFT OUTER JOIN scratchpads_statistics_term sst ON sst.term LIKE t.name
INNER JOIN users u ON u.uid = node.uid
INNER JOIN scratchpads_statistics_user ssu ON ssu.email = u.mail
LEFT OUTER JOIN node_counter nc ON nc.nid = node.nid
INNER JOIN node_revision nr ON nr.nid = node.nid
INNER JOIN users ru ON ru.uid = nr.uid
INNER JOIN scratchpads_statistics_user ssu_r ON ssu_r.email = ru.mail
WHERE (node.type = 'ecological_interactions')
ORDER BY nid ASC
For example on hosts.myspecies.info
More info from @edwbaker:
NB: I've temporarily disabled this function until this issue is solved
big sites also cause a similar problem for scratchpads_statistics -this has been disabled on the hosts scratchpad too through this PR and a variable set on the hosts.myspecies.info scratchpad
The sql generated by scratchpads_statistics that ends up making the server hang: