Welcome!

You will be redirected in 30 seconds or close now.

ColdFusion Authors: Yakov Fain, Jeremy Geelan, Maureen O'Gara, Nancy Y. Nee, Tad Anderson

Related Topics: ColdFusion

ColdFusion: Article

FusionDebug Tips, Tricks, and Traps

Going beyond the basics

FusionDebug is an easy straightforward tool, but if you leverage the experience of others, you can be even more productive.

Elsewhere in this issue, Jeff Houser introduces the FusionDebug interactive step debugger. I'd like to carry that discussion a bit farther and share various tips, tricks, and traps I've learned from my experience with the tool and that I've gleaned from available FusionDebug resources. I've been using FusionDebug (FD) for a couple of months now and am a fan.

First I'd like to share some general tips that address some common questions or concerns I've observed, broken down into tips on installation and general use. These should help you appreciate the tool's use and how to make the most of its available features.

Then I'd like to share some tricks or features that you may not readily notice that will make the tool still more useful. Finally, I'll share some traps or problems that you may encounter and how to resolve them.

Tips on Getting Started
Why Bother Using a Debugger?
Perhaps the first and most important tip to share is my perspective on why I think FusionDebug is an important tool. I realize that there are some who dismiss it or may simply feel that there's nothing it can do that CFDUMP or CFOUTPUT can't. I disagree and have addressed those concerns in the first two entries in a series in my blog at http://carehart.org/blog/client/index.cfm/fusiondebug.

What If You Have Problems Using or Installing the Tool?
If you have problems using or installing it, you'll find that FusionDebug support is great. The folks at Intergral, who also make FusionReactor, offer free support for the tool at [email protected].

How Do You Learn About Using and Installing the Tool?
The vendor's site, at www.fusiondebug.com, offers several very useful resources, including a well-done User Guide and Captivate videos showing how to use the tool, all online and free. There are also ample support FAQs and articles on the site to help solve common installation and troubleshooting glitches.

"I Really Don't Want to Switch to Eclipse"
Here's really good news: you don't have to switch to Eclipse. Yes, the tool does run atop Eclipse, as Jeff explains, but you don't have to give up your favorite CFML editor, whether it's Dreamweaver, HomeSite+, or something else. Use those for editing, and fire up Eclipse (and FD) when you debug.

And you don't necessarily have to install Eclipse, as you may already have it installed. Are you using FlexBuilder? That, too, is an implementation of a commercial plug-in atop Eclipse. You could add FD to that. If you do, when you're debugging Flex apps the tool will switch "perspectives" when control passes from the Flex app to the CFML page it calls.

"I Don't Want to Risk Hurting My Current Eclipse Implementation"
On the other hand, you may want to think twice about installing FusionDebug on top of FlexBuilder or even the CFEclipse-based implementation of Eclipse you may have. If you have any concerns about one plug-in hurting another, remember, you can install more than one copy of Eclipse. When you download it from Eclipse.org, it's just a zip full of files that you extract to a directory. It's okay to install it more than once in a different directory.

Along the same lines, another reason not to install FD atop a FlexBuilder install is if you're running the FlexBuilder trial. When it expires, you'll no longer be able to open that version of Eclipse.

Tips on General Use
Does It Just Debug CFM Pages? I'd Like to Debug CFCs and Calls from Flex, AJAX, Web Services, and Such
Great news: it not only debugs CFM pages but CFCs as well. Regardless of whether you instantiate the CFC in CFML or invoke it via Flex, AJAX, Web Services, Flash or Flash Remoting, or CFMX 7's gateways, FusionDebug will intercept the request.

More than that, the tool is savvy enough to recognize that there are special variables inside a CFC or method, and it will show the var (function local scope) and the "this" scopes in the "variables" pane.

Further, when debugging in a CFC method, there will be additional information in the "stack trace" pane. This is the pane (top left as typically configured in FusionDebug) that shows the filename and line number of the line where control has stopped. When control is stopped in a CFC method, this will also show the function name for the method.

Can It Debug CFSCRIPT Code?
Again, for some reason, many seem to have low expectations for the tool and often ask if it can debug code in CFSCRIPT. It absolutely can.

What Does "Step Into" Mean?
"Step into", when used on a line that would go into a new  file such as a CFC method, CFINCLUDE, or custom tag, will open that new file and show the first line of CFML code in that file.

What Does the User See While a Page Is Being Debugged?
When a browser requests a page that's being debugged and has stopped at a breakpoint, it will appear to be hung until the code sends output.

I Want to Be Able to See the Output Being Generated During Debugging
Following on to the previous tip, you may not see the output being sent to the browser while in the midst of processing breakpoints because ColdFusion buffers output until the page completes or the page buffer fills, or a CFFLUSH tag is executed. While it would be nice if the tool offered a pane to see the output as it's being generated, you have a couple of other options if you really want to see the output during debugging. You could insert CFFLUSH tags periodically in the page, or use the available CFFLUSH INTERVAL attribute to cause flushing after a certain number of bytes. Just be aware that, as explained in the CF docs, the browser may not display partial-page output if enough data hasn't been sent or until certain tags are closed (e.g., images, tables, and frames).


More Stories By Charlie Arehart

A veteran ColdFusion developer since 1997, Charlie Arehart is a long-time contributor to the community and a recognized Adobe Community Expert. He's a certified Advanced CF Developer and Instructor for CF 4/5/6/7 and served as tech editor of CFDJ until 2003. Now an independent contractor (carehart.org) living in Alpharetta, GA, Charlie provides high-level troubleshooting/tuning assistance and training/mentoring for CF teams. He helps run the Online ColdFusion Meetup (coldfusionmeetup.com, an online CF user group), is a contributor to the CF8 WACK books by Ben Forta, and is frequently invited to speak at developer conferences and user groups worldwide.

Comments (0)

Share your thoughts on this story.

Add your comment
You must be signed in to add a comment. Sign-in | Register

In accordance with our Comment Policy, we encourage comments that are on topic, relevant and to-the-point. We will remove comments that include profanity, personal attacks, racial slurs, threats of violence, or other inappropriate material that violates our Terms and Conditions, and will block users who make repeated violations. We ask all readers to expect diversity of opinion and to treat one another with dignity and respect.


@ThingsExpo Stories
As popularity of the smart home is growing and continues to go mainstream, technological factors play a greater role. The IoT protocol houses the interoperability battery consumption, security, and configuration of a smart home device, and it can be difficult for companies to choose the right kind for their product. For both DIY and professionally installed smart homes, developers need to consider each of these elements for their product to be successful in the market and current smart homes.
SYS-CON Events announced today that Avere Systems, a leading provider of enterprise storage for the hybrid cloud, will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Avere delivers a more modern architectural approach to storage that doesn't require the overprovisioning of storage capacity to achieve performance, overspending on expensive storage media for inactive data or the overbui...
Widespread fragmentation is stalling the growth of the IIoT and making it difficult for partners to work together. The number of software platforms, apps, hardware and connectivity standards is creating paralysis among businesses that are afraid of being locked into a solution. EdgeX Foundry is unifying the community around a common IoT edge framework and an ecosystem of interoperable components.
SYS-CON Events announced today that Avere Systems, a leading provider of hybrid cloud enablement solutions, will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Avere Systems was created by file systems experts determined to reinvent storage by changing the way enterprises thought about and bought storage resources. With decades of experience behind the company’s founders, Avere got its ...
High-velocity engineering teams are applying not only continuous delivery processes, but also lessons in experimentation from established leaders like Amazon, Netflix, and Facebook. These companies have made experimentation a foundation for their release processes, allowing them to try out major feature releases and redesigns within smaller groups before making them broadly available. In his session at 21st Cloud Expo, Brian Lucas, Senior Staff Engineer at Optimizely, will discuss how by using...
In this strange new world where more and more power is drawn from business technology, companies are effectively straddling two paths on the road to innovation and transformation into digital enterprises. The first path is the heritage trail – with “legacy” technology forming the background. Here, extant technologies are transformed by core IT teams to provide more API-driven approaches. Legacy systems can restrict companies that are transitioning into digital enterprises. To truly become a lead...
SYS-CON Events announced today that CAST Software will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. CAST was founded more than 25 years ago to make the invisible visible. Built around the idea that even the best analytics on the market still leave blind spots for technical teams looking to deliver better software and prevent outages, CAST provides the software intelligence that matter ...
SYS-CON Events announced today that Daiya Industry will exhibit at the Japanese Pavilion at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Ruby Development Inc. builds new services in short period of time and provides a continuous support of those services based on Ruby on Rails. For more information, please visit https://github.com/RubyDevInc.
As businesses evolve, they need technology that is simple to help them succeed today and flexible enough to help them build for tomorrow. Chrome is fit for the workplace of the future — providing a secure, consistent user experience across a range of devices that can be used anywhere. In her session at 21st Cloud Expo, Vidya Nagarajan, a Senior Product Manager at Google, will take a look at various options as to how ChromeOS can be leveraged to interact with people on the devices, and formats th...
SYS-CON Events announced today that Yuasa System will exhibit at the Japan External Trade Organization (JETRO) Pavilion at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Yuasa System is introducing a multi-purpose endurance testing system for flexible displays, OLED devices, flexible substrates, flat cables, and films in smartphones, wearables, automobiles, and healthcare.
SYS-CON Events announced today that Taica will exhibit at the Japan External Trade Organization (JETRO) Pavilion at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Taica manufacturers Alpha-GEL brand silicone components and materials, which maintain outstanding performance over a wide temperature range -40C to +200C. For more information, visit http://www.taica.co.jp/english/.
Enterprises have taken advantage of IoT to achieve important revenue and cost advantages. What is less apparent is how incumbent enterprises operating at scale have, following success with IoT, built analytic, operations management and software development capabilities – ranging from autonomous vehicles to manageable robotics installations. They have embraced these capabilities as if they were Silicon Valley startups. As a result, many firms employ new business models that place enormous impor...
SYS-CON Events announced today that SourceForge has been named “Media Sponsor” of SYS-CON's 21st International Cloud Expo, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. SourceForge is the largest, most trusted destination for Open Source Software development, collaboration, discovery and download on the web serving over 32 million viewers, 150 million downloads and over 460,000 active development projects each and every month.
SYS-CON Events announced today that Dasher Technologies will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. Dasher Technologies, Inc. ® is a premier IT solution provider that delivers expert technical resources along with trusted account executives to architect and deliver complete IT solutions and services to help our clients execute their goals, plans and objectives. Since 1999, we'v...
SYS-CON Events announced today that MIRAI Inc. will exhibit at the Japan External Trade Organization (JETRO) Pavilion at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. MIRAI Inc. are IT consultants from the public sector whose mission is to solve social issues by technology and innovation and to create a meaningful future for people.
SYS-CON Events announced today that Massive Networks, that helps your business operate seamlessly with fast, reliable, and secure internet and network solutions, has been named "Exhibitor" of SYS-CON's 21st International Cloud Expo ®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. As a premier telecommunications provider, Massive Networks is headquartered out of Louisville, Colorado. With years of experience under their belt, their team of...
SYS-CON Events announced today that TidalScale, a leading provider of systems and services, will exhibit at SYS-CON's 21st International Cloud Expo®, which will take place on Oct 31 - Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA. TidalScale has been involved in shaping the computing landscape. They've designed, developed and deployed some of the most important and successful systems and services in the history of the computing industry - internet, Ethernet, operating s...
Coca-Cola’s Google powered digital signage system lays the groundwork for a more valuable connection between Coke and its customers. Digital signs pair software with high-resolution displays so that a message can be changed instantly based on what the operator wants to communicate or sell. In their Day 3 Keynote at 21st Cloud Expo, Greg Chambers, Global Group Director, Digital Innovation, Coca-Cola, and Vidya Nagarajan, a Senior Product Manager at Google, will discuss how from store operations...
In a recent survey, Sumo Logic surveyed 1,500 customers who employ cloud services such as Amazon Web Services (AWS), Microsoft Azure, and Google Cloud Platform (GCP). According to the survey, a quarter of the respondents have already deployed Docker containers and nearly as many (23 percent) are employing the AWS Lambda serverless computing framework. It’s clear: serverless is here to stay. The adoption does come with some needed changes, within both application development and operations. Tha...
SYS-CON Events announced today that IBM has been named “Diamond Sponsor” of SYS-CON's 21st Cloud Expo, which will take place on October 31 through November 2nd 2017 at the Santa Clara Convention Center in Santa Clara, California.