[drupal-devel] [feature] Add timing information to statistics page

moshe weitzman drupal-devel at drupal.org
Wed May 11 21:20:50 UTC 2005

Issue status update for http://drupal.org/node/22623

 Project:      Drupal
 Version:      cvs
 Component:    statistics.module
 Category:     feature requests
 Priority:     normal
 Assigned to:  Anonymous
 Reported by:  Dries
 Updated by:   moshe weitzman
 Status:       patch

in the pdf, i think you are swapping 'total' and 'average' column

moshe weitzman

Previous comments:

May 11, 2005 - 15:05 : Dries

Attachment: http://drupal.org/files/issues/timer.patch (8.56 KB)

I extended the current timer_start() function in bootstrap.inc and added
two new function, timer_read() and timer_stop().  I've used these to
profile drupal.org.  (A small change will be needed to devel.module.)

I've also extended the accesslog-table to keep track of page generation
times.  The information is shown on the "top pages" page
(admin/logs/pages).  It shows each page's average page generation time,
and the total page generation time.  This lets one identify (i) slow
pages and (ii) resource heavy pages.  This is the most essential and
most useful information when tuning your Drupal site.

Please review, or I'll commit it as is.


May 11, 2005 - 15:13 : Dries

Attachment: http://drupal.org/files/issues/timer.pdf (22 KB)



May 11, 2005 - 16:04 : Dries

Setting to patch.  Take a look at the patch + screenshot please.


May 11, 2005 - 16:19 : moshe weitzman

looks ok ... note that there are some unrelated (i think) variable_set()
changes in the patch.


May 11, 2005 - 16:20 : Amazon

It's great to have this level of logging granularity.

I am concerned that all the logging would add over head when having
multiple crawlers crawling the site during testing.  Would it be
possible to support batching the log entries and submitting them to the
database as batch query at set increments instead of for every page.

For example I routinely run several wget crawls for different roles
when testing an upgrade.  If I ran 5 crawlers and each of 10, 000+
pages were being crawled then I am concerned the performance would be

I understand this isn't the intent of this patch but non intrusive
logging is important in generating accurate performance measurements.

Thank-you for your consideration.


More information about the drupal-devel mailing list