We have too many forum topic nodes (~160k) so the front page is slow.

Why not add option to remove this column?

This is not fixing #1632260: Performance issues with advanced_forum_statistics_replies but allow for just skip the whole query

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

clemens.tolboom’s picture

Version: 7.x-2.1 » 7.x-2.x-dev
Status: Active » Needs review
FileSize
3.96 KB

The patch needs work as I haven't figured out how to hide the 'Last post' column yet.

[edit]
On our site having ~160K topics this improves performance from 32628.94 ms to 507.11 ms for the
/forum
page. Just visit the settings page on
/admin/config/content/advanced-forum
to disable statistics 'Latest post' column

helmo’s picture

I see two options to hide the column.

* add a condition to styles/naked/advanced-forum.naked.forum-list.tpl.php
* add some custom css to 'display: none' to class="forum-last-post" and class="forum-last-reply"

Dries Arnolds’s picture

Good work. Hope this gets committed. I'll test it shortly.

@helmo, option 1 is the most elegant solution. Hiding with CSS is something that should only be used as a last resort.

podarok’s picture

Issue summary: View changes
Status: Needs review » Closed (works as designed)