The _CF_NODEBUG Parameter

Most people know that enabling request debugging output via the ColdFusion administrator has some overhead. If you are running a CFC heavy application the performance hit can be quite noticeable. To get around the performance issues you may be tempted to use <cfsetting> with the showdebuoutput attribute set to false. While this does indeed suppress the debugging output, it does not disable the debugging service or alleviate the performance issues you may see with debugging. You can confirm this using the following template:

[More]

Flex Remoting to CFCs under a Fusebox 5.5.1 Application.cfc

I recently started using Fusebox again and one issue I ran into was that Flex Remoting calls to CFCs under my Fusebox application were not working. (The application in question used an extended version of Fusebox's Application.cfc.) To work around the issue I put the remote components under a different, minimal, Application.cfc which used the same name as my main applicaiton. Something like the following:

<cfcomponent>
<cfset this.name="myApp" />
</cfcomponent>

This fixed the issue, but I was still a little puzzled. It is well know that the Application.cfc onRequest method doesn't play well with Flex Remoting, but I looked at Fusebox's Application.cfc and thought it was handling the issue with the following code in onRequestStart:

<!--- ensure CFC / Web Service / Flex Remoting calls are not intercepted --->
<cfif right(arguments.targetPage,4) is ".cfc">
<cfset doCompile = false />
<cfset structDelete(variables,"onRequest") />
<cfset structDelete(this,"onRequest") />
<cfreturn/>
</cfif>

Well, today I had a little bit of time to look into this and it turns out that for Flex Remoting requests the targetPage is "/flex2gateway," not the name of the target CFC. It was a bit of a "duh" moment, because if you have ever looked at a services-config.xml file or watched Flex Remoting requests via a proxy like ServiceCapture then you know the URL used is something like http://localhost/flex2gateway. Anyway, to fix the issue I ended up modifing the Fusebox Application CFC code above to the following:

<cfif right(arguments.targetPage,4) is ".cfc" or findNoCase("/flex2gateway",arguments.targetPage) gt 0>
<cfset doCompile = false />
<cfset structDelete(variables,"onRequest") />
<cfset structDelete(this,"onRequest") />
<cfreturn/>
</cfif>

Now I no longer need to remember to add a custom Application.cfc for remote CFCs.

It is important to note that Flash Remoting can be configured to use any URL, but this at least covers the default configuration for ColdFusion.

BlogCFC was created by Raymond Camden. This blog is running version 5.8.001.