Displaying performance metrics in a modern web app?
Posted
by Charles
on Stack Overflow
See other posts from Stack Overflow
or by Charles
Published on 2010-05-29T15:50:13Z
Indexed on
2010/05/29
15:52 UTC
Read the original article
Hit count: 219
We're updating our ancient internal PHP application at work. Right now, we gather extensive performance measurements on every pageview, and log them to the database. Additionally, users requested that some of the metrics be displayed at the bottom of the page. This worked out pretty well for us, because the last thing that the application does on every request is include the file containing the HTML footer.
The updated parts of the application use an MVC framework and a Dispatch/Request/Response loop. The page footer is no longer the last thing done. In fact, it could very well be the first thing done, before the rest of the page is created.
Because we can grab the Response before it's returned to the user, we could try to include placeholders for the performance metrics in the footer and simply replace them with the actual numbers, but this strikes me as a bad idea somehow.
How do you handle this in your modern web app? While we're using PHP, I'm curious how it's done in a Ruby/Rails app, and in your favorite Python framework.
© Stack Overflow or respective owner