We added a debugging template called debugging-neo.cfm which displays as the well known debugging output of MX. Next to this one we added two interesting debugging templates.
- debugging-comment.cfm
- debugging-cascade.cfm
<!-- Debugging: ========================================================================================================================================= | SOURCE | COUNT | LOAD | QUERY | APP | TOTAL | ----------------------------------------------------------------------------------------------------------------------------------------- | ra://D:\Projects\davidoff\WEB-INF\railo\context\railo-context.ra!/admin/development.debugging.cfm | 1 | 0 | 0 | 47 | 47 | | D:\Projects\davidoff\WEB-INF\railo\context\templates\debugging\debugging-comment.cfm | 1 | 0 | 0 | 0 | 0 | ... more lines ... | ra://D:\Projects\davidoff\WEB-INF\railo\context\railo-context.ra!/admin/resources/text.cfm | 1 | 0 | 0 | 0 | 0 | | ra://D:\Projects\davidoff\WEB-INF\railo\context\railo-context.ra!/admin/web_functions.cfm | 1 | 0 | 0 | 0 | 0 | | TOTAL | 0 | 1 | 0 | 47 | 47 | ========================================================================================================================================= -->The prefix ra:// indicates that a certain file is taken from a railo archive. Then you have 5 columns telling you how often a template has been called, how long it took to compile and load, how long queries took inside the template, how long the template took to process and the total time the template consumed.
The other one called debugging-cascade.cfm is one that makes usage of cookies in order to expand information.

The list of executed templates is colored from red to green depending on the execution time. Red - slower, green - fast. The percentage of time is display next to the template, so that you can see wich of your templates consumes the largest amount of time. I guess the numbers are self-explanatory.
You can set several options like sorting of executiontimes, sql queries etc. In order to save time you can prevent sql or template output from being displayed. In addition to that dumps of several scopes can be displayed as well.
A small goodie is the replaySQL button (green play icon) which allows you to replay the sql statement and display the results in a new window, since this is something users might often do.
The result looks like this:

At the bottom of the page you have an anchor which brings you to the top of the debugging, since sometimes you have to scroll a lot in order to find it.
Follow this link to download the set of debugging templates we have at the moment. If you have any comments, just drop a message.
The debugging-2-console template is quite usefull for background debugging. If you made any improvements to some of the templates, just send them to me and we will try to implement them in upcoming releases.
My personal favorite is debugging-2-console since it has some features I really often need. Cumulating query times, background debugging and much more. I would appreciate your comments.
5 responses so far ↓
1 Jeff Gladnick // Mar 8, 2007 at 4:07 PM
2 Peter Boughton // Mar 9, 2007 at 10:58 AM
I've been a bit frustrated over how long the CF debugging can be - always showing information I sometimes but not always want; being able to expand and collapse the sections is going to be lovely.
Also, that replay SQL feature is a genius idea!
I'm frequently having to copy and paste queries into Metapad, replace out tabs and replace in variables, just so I can run the same query again. Now I'll be able to just click a button. :)
3 Gert Franz // Mar 9, 2007 at 11:27 AM
Just to mention. When you use the debug-2-console template you need to call /railo-context/templates/display/debugOutput.cfm in order to see the output. The template only writes a HTML comment into the result output.
Gert
4 Martyn // Jul 1, 2009 at 12:34 AM
Thanks!
5 Gianna // Sep 7, 2009 at 12:50 PM
Leave a Comment