Debugging and the ColdFusion Administrator


As you begin to think about debugging your applications, one of the first places that you'll likely want to look is in the Debugging and Logging section of the ColdFusion Administrator.

In this section of the ColdFusion Administrator, you can choose the type of debugging information that you'd like to have displayed in the output of your pages. You can also choose how you'd like to have that information displayed and control who has access to it.

Debugging Settings Page

Inside ColdFusion Administrator are two sections that affect how debugging output is presented to you. The first of these pages is the Debugging Settings page. Figure 14.1 gives you an overview of this page in the Administrator.

Figure 14.1. Debugging Settings page of the ColdFusion Administrator.

graphics/14fig01.gif

On this page, you can adjust the format for the debugging output that you receive, as well as what specific types of information you'd like to have displayed in your debugging output.

Table 14.1 gives you an overview of what each setting on this page will do for you and how each setting can be adjusted.

Table 14.1. Debugging Settings Within the ColdFusion Administrator

Debugging Setting

What Does It Do?

Enable Debugging

This is the most basic of the debugging settings included in the Administrator. This option toggles debugging information.

When this box is checked, debugging information is displayed to all users who visit your ColdFusion Markup Language (CFML) pages, unless you've limited the debug output to a specific Internet Protocol (IP) address or group of addresses.

This option enables you to choose the way in which you'd like to have your debugging information displayed on your output pages.

The classic.cfm option presents all debugging information in the familiar "HTML at the bottom of the page" format that you should be used to from earlier versions of ColdFusion.

The dockable.cfm option encapsulates all your debugging information in a Dynamic Hypertext Markup Language (DHTML) expanding tree in a separate browser window. You then can choose to have this menu float or dock itself in the current browser window.

Report Stack Trace of n Depth

Turning this option on presents a report of all ColdFusion pages that have run in response to a single Hypertext Transfer Protocol (HTTP) request.

The execution time for all pages is also listed. The text box enables you to specify how "deep" you want the ColdFusion Server to go in reporting on templates that run.

Database Activity

Turning this option on causes debugging information related to your datasources and stored procedures to be displayed along with your other ColdFusion debugging information.

Exception Information

Checking this check box enables ColdFusion to report to you a list of any exceptions that are encountered during the processing of the ColdFusion request.

Tracing Information

When turned on and used in conjunction with the new CFTRACE tag, this feature enables tracing information for each instance of the CFTRACE tag to be reported in the debugging information of the page.

Locking Warnings

When turned on, this feature enables the ColdFusion Server to report to you any unlocked shared scope variable accesses that it encounters.

Variables

When this check box is clear, no variable information is displayed in the debugging output of the page. When turned on, you can select the types of variables for which you'd like to see debugging information.

This feature helps you "clean up" your debugging information when you're troubleshooting specific types of errors.

Debugging IP Address Restrictions

The next section of the Administrator that deals with debugging is the Debugging IP Address Restrictions section. In this section, you control who can see the debugging information being reported by your servers.

As a general rule, on any production server, you'll want to have debugging information completely disabled so that you do not expose any sensitive information about your server to the general public not to mention having a rather unsightly set of CFML templates.

Even in development environments, certain groups of developers might need access to debugging information that you might not want everyone working on the project to see. In those situations, you would use the Debugging IP Address Restrictions section of the ColdFusion Administrator to limit the debugging output specifically to whom you want to receive it.

Figure 14.2 gives you a look at the Debugging IP Address Restrictions page within the ColdFusion Administrator.

Figure 14.2. Debugging IP Address Restrictions page.

graphics/14fig02.gif

After you've enabled debugging on your development servers, you'll want to come to this page to specify those users whom you'd like to be able to view that debugging information.

By default, when debugging is enabled, only users on the server itself (the 127.0.0.1 or localhost address) can see the debugging information. To add other users to the list of people who can view the debugging information, you simply put their IP addresses in the IP Address text box on this page and click the Add button.

After you've done this, you'll notice the IP address that you've just added is now transferred to the Selected IP Addresses for Debug Output text box. To remove a user from this list, highlight his or her IP address and click the Remove Selected button at the bottom of this page.



Inside ColdFusion MX
Inside Coldfusion MX
ISBN: 0735713049
EAN: 2147483647
Year: 2005
Pages: 579

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net