Check out our Angular Book Series.

How do I move ColdFusion Configuration to Another machine without Exporting Settings?

I've written in the past about migrating ColdFusion instances from one machine to another. Most of the time when I have to do this it is because of a hardware failure and I'm setting up a machine from scratch. This seems to happen every 4-6 years. Despite it's impending immediate death, 20 years running, I still do a quite bit of ColdFusion development. It's the devil that I know on the server side.

Without a working machine, I can't sign into the CF Administrator and export CF Admin settings, so I have to go to other methods to get my config up and running. I've written about similar experiences with ColdFusion 8 and migrating from ColdFusion 8 to 9. But, time moves on and most of my production clients use CF10, so that is the version I have installed on my local.

How do I get the old CF configuration set up the new machine when all I have access to is the old CF installation directory? this is how I did it.

  1. Install Apache: ColdFusion is useless without a web server, so first I installed and configured the Apache web server.
  2. Install ColdFusion 10: Get ColdFusion 10 from the cfmlRepo site. More specifically, go here. be sure to download app the patches. And send thanks to whomever takes care of that site.
  3. Install CF Hotfixes: Next, install all the ColdFusion hotfixes. You'll have to install the first few manually before you can use the update feature inside the ColdFusion administrator. Uses these instructions, but basically do this:

    C:\ColdFusion10\jre\bin\java -jar hotfix_008.jar

    I installed hotfixes 7-13. The rest I updated through the ColdFusion administrator.

  4. Compare Directories: Now compare your old ColdFusion install directory to the new ColdFusion install directory. You'll be surprised at how many of the files will be flagged as identical. Those aren't the ones you need to worry about. I focused on the config files in cfusion\lib\*.xml, and copied them over from the old directory to the new one. These are the configurations I moved:
    • new-cron.xml: Not sure what this one is for.
    • neo-datasource.xml: this file contains DSN configuration information.
    • neo-debug.xml: This contains CF Debugging settings.
    • neo-logging: This contains log related settings.
    • neo-mail.xml: This contains mail server settings.
    • neo-metric.xml: I couldn't figure out which settings this one contains, but I copied it anyway.
    • neo-runtime.xml: This file contains misc settings.
    I was making some educated guesses here. I think Neo was the code name for ColdFusion MX, so it is funny to see the name still kicking around.
  5. Restart ColdFusion: After the restart, you should find all your CF settings restored.
  6. Change DNS Passwords: I did notice that I had to reenter the passwords for all my data sources.

Overall, the process worked a lot better than I would have hoped.

Keep up to date by reading DotComIt's Monthly Technical Newsletter

Thoughts on Adobe's ColdFusion Roadshow in New York

Adobe had a ColdFusion Roadshow Event in New York last week and I attended. I had a moment between two projects, so I thought why not take a trip to the city and network a bit?

I wanted to formalize some of my thoughts about the event in no particular order.

I was personally invited by Kishore Balakrishnan, the Senior Product Marketing Manager for Adobe ColdFusion. I'm not sure why I got the invite. My software development company has been an Adobe partner in the past, but not in ages. I was part of the Adobe ACP program in the past, but am not currently a member. It could be that they just emailed everyone who had downloaded CF from their website. I'm not sure, but I also didn't ask.

The even was sparsely attended, maybe 20 people tops. I did meet someone from one town over who is running a medical startup that plans to use ColdFusion. That was a treat.

The event started with a presentation by Elishia Dvorak about What's new in ColdFusion 2016. My big takeaway was that they had built an API Manager tool. This is a way to manage REST APIs, whether they are built in CF or something else. This is a completely separate product from ColdFusion. I sounded to me like a proxy or entry point that could be used to manager other APIs, load balancing, documentation, and user management. I can see a benefit if you're a big company moving to a reusable service based architecture to power your organization, or a company whose business is providing services to external clients or vendors. It was an interesting approach. Since I've focused on UI Programming I don't know what else is out there that does that. If you need something like this, and are already a ColdFusion customer, it is worth checking out.

Everything else new to CF was related to performance, security, and stability. Apparently when Adobe talks to customers there are the three areas of focus. I'm not surprised, though. ColdFusion is a mature technology that does what I need it to do. What is left to add? I've had trouble answering that question for 10 years.

Then Kishnore got up to present about Tackling Future Challenges using ColdFusion. He started by talking about how ColdFusion success. Apparently ColdFusion is thriving. They said that each release doubles the sales of the previous release. I'm a bit surprised by the numbers. The next version of ColdFusion will be released in 2018, the only feature I can recall was a revamped version of CFScript which will offer more OO Features. And of course, more stability, better performance, and better security. All good things, but not the whiz bangy features to make new people interested.

Since ColdFusion is doubling it's sales with each release that means there must be a huge demand, right? Nope! The two biggest complaints from the audience were the inability to find CF Developers and the inability to find CF Jobs. I hope those two networked with each other. My impression is that the ones who can't find CF Developers are you for beginners. The bulk of CF Devs have lots of experience with it, and no new blood is coming into the fold. Kishnore suggested that CF is easy to train people in. I agree. However, another attendee complained that it is hard to book people for CF Training courses from major training centers. The course always gets cancelled last minute because not enough people signed up. That is troublesome and won't help train up a new breed of devs. The topic of IDEs came up. A lot of people complained about CF Builder, how it is a mess, but and how they still use Dreamweaver. I have to admit this surprised me to find people are using Dreamweaver for coding? I admit that Eclipse, which is the base of CF Builder, takes a learning curve. For simple code hinting, IntelliJ has addressed my needs well. It is also worth nothing that CF Builder is now included with the license cost of CF. That's a nice touch.

The topic of Rapid Application Development came up, and the attendees agreed that CF is RAD. I agree, especially when compared to Java. However, a lot of attendees said nothing can beat CF. I'm not sure that is still the case. One big benefit to CF being a RAD language is that it is loosely typed. However, a lot of server platforms offer that today. I was left with the impression that a lot of attendees had not played with more current tech. I do expect that you'll be more effective when dealing with a tech you've worked with for 20 years than you will be with something you just learned. But, once up the learning curve of new technology I'm not sure CF has the lead many championed. I worry that CFs push to add more Object Oriented features may hinder CF's RAD ability.

With such high sales numbers, I'm a bit surprised that they couldn't get a bigger crowd in NYC. My perception is that CF has big usage in government, but it seems all but abandoned in the commercial markets I usually work in.

Those are some random thoughts on the experience. Primarily I focus on UI technologies these days, but still have a few CF clients and every now and then. I'm glad I could fit the visit into my schedule. I'm glad CF is still around and kicking.

Why doesn't Flex Remoting work with ColdFusion 10 and Apache Web Server?

I'm doing some maintenance on an AIR application with a ColdFusion backend. For testing purposes, I installed a brand new copy of ColdFusion 10 and Apache Web Server 2.2.

My first step was to test this new setup the Flex Remoting connection between ColdFusion and Flex. It was borked! The flex2remoting URL would return a 404. What was wrong? I do not remember having problems in the past. ColdFusion 10 introduced a new version of Flex Remoting, so maybe that was somehow the cause. There are a few people complaining about errors they've encountered. I tried all the fixes.

First, I tried tweaking ColdFusion's file, as described by my good friend Joseph. That didn't work for me. I found another suggestion which recommended commenting out some lines of ColdFusion's web.xml file. No luck there either. I went over all of ColdFusion's Flex Remoting Configs in an attempt to find something amiss, no luck.

I started grasping at straws and experimenting. I know that in IIS, there is a virtual directory called Jakarta which is a Java Mapping and helps Flex Remoting, among other things run. Does Apache have something similar and could the setup be wrong? Apparently the answer is yes! Open up the mod_jk.conf file. It was created when you used the ColdFusion Web Server Configuration Tool to configure the Apache web server. There are a bunch of 'jk' properties:

LoadModule jk_module "C:\ColdFusion10\config\wsconfig\1\"
JkWorkersFile "C:\ColdFusion10\config\wsconfig\1\"
JkMountFile "C:\ColdFusion10\config\wsconfig\1\"

As best I can tell this is the Apache equivalent of the Jakarta mapping in IIS. I started researching the different options around the module loading.

When using virtual hosts with Apache Web Server, the mappings do not trickle down. I added this command to my Apache config:

JkMountCopy All

And everything started working magically.

There are reports of similar problems with CF11. It is frustrating that problems like this still exist.

How to fix Exceeded limit of maxWarmingSearchers=4 in ColdFusion

A new old client approached me. I hadn't worked for them in a decade, and I suspect their code base is twice as old as that. Don't we all love looking at old code?

The site was built with ColdFusion and used ColdFusion's underlying search engine to search files on their site. Ten years ago, the search engine in ColdFusion was Verity and we could index sites using the cfindex tag. However, over time Verity was replaced with Solr. This inadvertently caused some issues when re-indexing their site.

The Problem

Their code to index the site was like this:

<cfindex action="update" collection="myCollection" type="file" key="someKey" urlPath="path" />

This was performed in a loop over all the new files in their site. Sometimes they did massive updates and the search indexing was failing.

The error was something like this:

Error opening new searcher.

Exceeded limit of maxWarmingSearchers=4, try again later

I set to work trying to fix it.

The Solution

If you search for this error you'll find a lot of information about the error and Solr; but none if it is particularly useful in the context of ColdFusion. The Solr engine is getting too many indexing requests and rejecting them. It took some experimentation, but I found a solution.

First, when you're indexing the site, add the autoCommit parameter to the tag and set it to false:

<cfindex action="update" collection="myCollection" type="file" key="someKey" urlPath="path" autocommit="false" />

This tells Solr to add the files to the search collection, but not to index them yet. After all the files have been added, perform a commit action:

<cfindex action="commit" collection="myCollection" />

Then all the files are indexed by the Solr engine at once. Discovering this was a bit tricky because the commit action is mentioned a few places in the documentation, but is not documented as a valid value for the action attribute of the cfindex tag.

After setting this up; everything worked great!

Why Won't ColdFusion 10 show my cfgraph on IIS 7.5?

I just spent half a day trying to figure out why ColdFusion 10 would not show my cfgraphs. I solved it, but not by the 'usual' means.

I have a production server locked down via the CF10 lockdown guide. It has been chugging along for a few years without any issues.

I was working on some code to generate some reports on some database data. Everything was working fine on my local install of the code; but when I pushed to production my graphs were blank.

The graph image was generated using something similar to this:


Because the server is locked down; the CFIDE directory is not located in the root directory of the server. Even if it were, GraphData.cfm does not refer to an actual file, but rather a server mapping.

The first thing I verified was that the graph data was actually being created. I thought that perhaps CF did not have write access to the directory it used to generate the chart files. Look here:


If you see files being generated in that directory, then access it not the problem. It was not for me.

Why was I getting broken image links when trying to load a page with dead graphs?

There are a people with this problem on the web, but most of the fixes did not work for me. Manually created a CFIDE folder and a GraphData.cfm folder did not work for me.

Manually creating an ide.cfm file in the CFIDE/main directory did not work for me.

So, what did work?

It turns out at the IIS level I had blocked a lot of URLs related to CFIDE directory. So, to fix my solution I had to remove these blocks.

Follow these steps:

  1. Open up your IIS Control Panel
  2. Click on Request Filtering
  3. Click on URL. If you have setup IIS to block the CFIDE folders, you'll probably see something like this:

  4. Right click on CFIDE/GraphData and click remove

My graphs immediately started showing up. Like magic!

Sign up for DotComIt's Monthly Technical Newsletter

Setting up my Dev Environment with ColdFusion 10, ColdFusion 11, and Apache Web Server

One of the first articles I wrote for the ColdFusion Developer's Journal was about setting up IIS to run on ColdFusion 5, ColdFusion MX, and BlueDragon. This was an article I co-wrote with my friend Charlie Arehart and it was published back in 2003. My intent was to write code once, and be able to test it on different application servers. This worked pretty well.

Nowdays I primarily use Apache Web Server for development purposes instead of IIS. ColdFusion has increased multiple version numbers. The need from the original article still exists. I currently do work on sites that use both ColdFusion 10 and ColdFusion 11. It'd be nice to be able to run both versions of ColdFusion side by side.

This article details how I set up my machine.

Installing ColdFusion

I already have CF10 installed on my machine, but need CF11. My first step was to download the ColdFusion 11 Developer Edition from the Adobe web site and follow the normal install instructions. You could install the EAR/WAR version of CF11 and deploy that using the CF10 instance manager. This is like running CF11 inside CF10. However, I decided to install CF11 in the server configuration mode; similar to how CF10 was previously installed.

During the install, you are given the option to configure your web server. Create a copy of your Apache Web Server conf directory and have the CF11 installer configure that copy. Then you can compare the two configurations to see what has changed. I was hoping that I would be able to make use of virtual servers, attach CF10 to some virtual servers, and CF11 to others. Unfortunately that is not possible.

The Problem

ColdFusion 10 and 11 both use Tomcat under the hood; a change since they have been using JRUN since CFMX when I wrote my initial article. In Apache, the JkShmFile directive is used to associate Apache with Tomcat servlet container. Unfortunately, only one JkShmFile directive can be in an Apache Web Server config; making it impossible to point different virtual servers in the same Apache instance to different versions of ColdFusion.

My Solution

I decided that I could use the same Apache installation with completely different configurations, one pointed at CF10 and one pointed at CF11. I wouldn't be able to run them at the same time unless I gave them different web server ports, but I would be able to do testing against different versions of ColdFusion. I decided this was suitable for my current needs.

This is how to run Apache from the command line and specify your custom config directory

[Apache Install Directory]\bin\httpd -k start -f "[Config Directory\httpd.conf"

The K parameter is used to start, restart, or stop the Apache Web Server depending of the value of the parameter. The f parameter specifies the location of the config file. The f parameter is key to launching Apache with different configs.

I did some testing with this and determined it was working great. But, I wanted to set it up as a service so it would show up in the control panel on my Windows machine. This command did that:

httpd -k install -n "MyServiceName" -f "[Config Directory\httpd.conf \httpd.conf"

Final Thoughts

Although I didn't take it this far, I could have shared a lot of configuration variables between the two servers through the use of Apache includes. That could be the topic of another article, though.

Sign up for DotComIt's Monthly Technical Newsletter

Manually configuring ColdFusion with IIS7

I sent this email out yesterday as part of the Flextras/DotComIt newsletter. I thought I'd repost it here.

I recently had the opportunity to move some of my hosted sites to Amazon web services. The Flextras site, The Flex Show, and my personal blog, are now all hosted on EC2. It has been a few years since I've had to deal with my own production server maintenance; and I came across a weird issue with IIS7 and ColdFusion 9. I thought I'd describe the issue and explain my solution.

IIS6 Compatibility is turned on

Normally, when you create a new instance of an IIS web server, you'll need to associate ColdFusion with it. ColdFusion provides a tool named the Web Server Configuration Tool that can attach an instance of ColdFusion with an instance of IIS. If you happen to be using ColdFusion 9.02--or later--and IIS7; you may receive this error:

The Web Server Configuration Tool will not work with IIS7 if IIS6 Management Compatibility is enabled. On this particular server, the management compatibility was enabled for the FTP plugin could be managed on the server. I did not want to uninstall the IIS management compatibility if I could avoid it. How could I tell IIS7 that it should send .cfm requests to ColdFusion for processing without using the Web Server Configuration Tool?

Editing the applicationHost.config file

Under the hood the mappings that tell IIS7 how to communicate with ColdFusion are in a file named applicationHost.config. You can find this file in the 'C:\Windows\System32\inetsrv\config\' directory. This file contains a lot of configuration for IIS7.

If IIS7 was already installed when ColdFusion was initially installed, then you can find a section that references an existing IIS7 instance with your existing ColdFusion instance. Look for something like this:

<location path="iisInstanceName">
<clear />
<add name="ISAPI-dll" path="*.dll" verb="*" modules="IsapiModule" resourceType="File" requireAccess="Execute" allowPathInfo="true" />
<add name="CGI-exe" path="*.exe" verb="*" modules="CgiModule" resourceType="File" requireAccess="Execute" allowPathInfo="true" />
<add name="AboMapperCustom-130401" path="*" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\1\jrun_iis6_wildcard.dll" requireAccess="None" responseBufferLimit="0" />
<add name="AboMapperCustom-130411" path="*.jsp" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="AboMapperCustom-130412" path="*.jws" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="AboMapperCustom-130413" path="*.cfm" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="AboMapperCustom-130414" path="*.cfml" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="AboMapperCustom-130415" path="*.cfc" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="AboMapperCustom-130416" path="*.cfr" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="AboMapperCustom-130417" path="*.cfswf" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="AboMapperCustom-130418" path="*.hbmxml" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="AboMapperCustom-130419" path="*.hbmxml" verb="*" modules="IsapiModule" scriptProcessor="C:\ColdFusion9\runtime\lib\wsconfig\jrun_iis6.dll" requireAccess="Script" responseBufferLimit="0" />
<add name="TRACEVerbHandler" path="*" verb="TRACE" modules="ProtocolSupportModule" requireAccess="None" />
<add name="OPTIONSVerbHandler" path="*" verb="OPTIONS" modules="ProtocolSupportModule" requireAccess="None" />
<add name="StaticFile" path="*" verb="*" modules="StaticFileModule,DefaultDocumentModule,DirectoryListingModule" resourceType="Either" requireAccess="Read" />

If you're using CF Standard, you can just copy and paste this section; then change the path name on the location to be the name of your new IIS7 server instance. Restart your IIS instance and that should be all you need. Otherwise, you'll have to create the above section manually; by copying and pasting from above and changing your paths to relate to your own CF Install.

Although I didn't have the experience of setting this up using CF Enterprise, I expect the procedure will be similar; you'll just need to point to the jrun_iis6.dll for your specific instance of ColdFusion.

How to Create a System for Caching Data

I wrote this article for the monthly Flextras newsletter, and thought I'd share it here.

I was working with a client recently and we had some performance problems while accessing remote data from within our application. The user interface, built with Flex, was accessing our ColdFusion server, and ColdFusion would relay requests onto another remote system using SOAP web services. The web service data didn't need constant updates, so we decided to create a caching system for the data to improve performance. I thought the concepts behind that would make an interesting topic for this month's newsletter.

What Type of Data to Store?

We decided it was best to create a generic system to cache any type of data. The system should handle any type of data we wanted to throw at it. To accomplish this, I created two classes a CacheManager class and CacheData class. The CacheData class is intended to be a generic object used by the CacheManager. Here is a diagram of the class:

The CacheData class is used by CacheManager to store the cached data. It has three properties: the data to store and two dates. The first date is, dateCached, which keeps track of the date and time that the data was first cached. The second element is dateLastAccessed, which keeps track of the date that the data was last accessed. The data property should be protected, or private, or something similar depending upon your language of choice. The two date properties should be publicly accessible.

The class has two methods: get() and set(). The get method returns the data and should also update the last accessed date value to the current date and time. The set method will update the internal data property, as well reset the two dates. In an attempt to keep this as platform agnostic as possible; this would be pseudo code for the class:

package{ class CacheData{
// this value stores the data
protected var data : *;
// this value stores the date that the data was initially stored
public var dateCached:Date
// this value stores the date that the value was last accessed
public var dateLastAccessed:Date
// this method can be used to retrieve the data
public function get ():*{
dateLastAccessed = getCurrentDate();
return data;
// this method can be used to set the data
public function set(value:*):void{
data = value;
dateCached = getCurrentDate();
dateLastAccessed = getCurrentDate();
} } }

This is a very simple class, not much more than a glorified value object.

The CacheManager Class

The CacheManager class is a bit more complicated. This is your application's window into the cached data.

This is the class diagram for the CacheManager:

The CacheManager has two properties; minutesCached and cachedData. The minutesCached property is an internal value will be used to determine when data should be flushed and deleted. The cachedData is also an internal value, but it is a bit more complicated. I created that as an associative array of associative arrays. In Flex, an associative Array would be a Dictionary; in ColdFusion that would be a Struct. The first key of the associative array is the type of data you want to store. I call this the cacheKey. This may be "products" or "orders" or something similar, depending on the data you want to store. The second associative array's key is the dataKey. Examples of this may be "ProductID1" or "Order13" or anything that can be used to uniquely identify the type of data, such as its database's Primary Key.

The combination of the dataKey and the cacheKey is used to retrieve the data. The use of the two key structure allows a single instance of the CacheManager to be used to cache multiple types of data. There are also two methods as part of the cacheManager: store() and retrieve(). The store method accepts three arguments: the data, the cacheKey, and the dataKey. It will create a new object of CacheData object and call the CacheData.set method to store the data. It is the simpler of the two methods.

The retrieve method is where the magic happens. It first check's to verify that the data exists. Then it checks to make sure that the data is still relevant based on the current date and the date that the data was last accessed. If the data is too old; then it can be deleted. Otherwise it can be returned. This is a pseudo code class:

package{ class CacheManager{
// this value specifies how many minutes the data should be cached
protected var minutesCached : int = 1440;
// this value contains the cached data; using a two key structure. A CacheKey and a DataKey.
protected var cachedData:Dictionary = new Dictionary();
// this method can be used to retrieve the data
public function store (data:*, cacheKey:String,dataKey:String):void{
cachedData[cacheKey] = new Dictionary();
cachedData[cacheKey][dataKey] = new CacheData();
return data;
// this method can be used to set the data
public function retrieve(cacheKey:String,dataKey:String):*{
var cacheObject = cachedData[cacheKey][dataKey]
if(!cacheObject){ return; }
var dateToClearCache :Date = getCurrentDate() - minutesCached
if(cacheObject.dateLastAccessed <= dateToClearCache){
cachedData[cacheKey][dataKey] = null; return;
} Return cacheObject;
} } }

Although it is beyond the scope of this article, you could also create a method to automatically clear old cache data. This is probably more memory efficient than waiting until the data is retrieved to clear it out.

Putting it All Together

Now that we have the code behind our CacheManager, the last step is to put that to use. First, create an instance of it; presumably in some globally accessible variable.

public var cacheManager :CacheManager = new CacheManager();

Let's say you just loaded a bunch of products from some remote source. You'd loop over them and store them in the CacheManager instance:

For each product in productArray (product, 'products',
End For Loop

In this code, we use the cacheKey named products and use a product ID for the dataKey. I once read something that said you when you file something; you want to make sure to file it in the way that you can find it when you need it. The dataKey for your cache should follow the same suit. When you need to retrieve the data, you want it to be filed under some name that you can use to retrieve the data later.

Retrieve the data from the cache when you need it, like this:

var product : Product = cacheManager.retrieve('products',;

Be sure to check that you actually got a product back from the cache before you try to use it:

// do something to retrieve the product data from source
// or make sure your code accommodates for a non-existent product
// process product

Final Thoughts

I hope you found this article interesting. I did my best to make this as conceptual as possible, so you may have to modify the code in order to work in the language of your choice.

I have two other mini-announcements that I added to the recent Flextras Newsletter. First, the code that never became the Flextras Flex Spreadsheet Component has been open sourced by the original author. It is a very impressive piece of technology. Second, if you're in the mood for interesting weird music; I recorded a full album worth of songs for February Album Writing Month. It is a nice little diversion from programming at times.

Flash Remoting won't connect "NetConnection.Call.Failed"

I've been doing some with for the Flextras promotions around 360|Flex. As part of the promotions I am creating a customized version of my Game; strictly for Flextras. It is going to allow people to login and will keep score on our server instead of internally to the app.

Since this is a Flash app; I'm using Flash Remoting to connect to our ColdFusion server. Everything worked fine on my local machine. Everything worked fine on my development server (AKA Staging). However, my production machine was giving errors that looked like this:

faultCode: "Client.Error.MessageSend"
faultDetail: "Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: Failed: url:
faultString: "Send failed"

I've tried a lot of different things including not using http instead of https. I knew that Flash Remoting was working on the production server because I had other Flex apps working without problems. So, what was the problem?

I've been working on this on and off for about five days; so tried a lot of different things. In the end I discovered two things:

  1. Make sure your Flash Remoting URL has a '/' at the end of it. '' was not working. It appeared to add a JSessionID on it; which was causing the server to throw a 404 error; causing the whole call to fail. However, if I changed this to '' that problem went away.
  2. Turn off the Flash Builder Network Monitor. The Flash Builder Network monitor was intercepting the call and causing it to fail. The calls appeared to work fine from a web browser with the Flash Builder Network Monitor enabled, but not from the mobile app.

I think--but am not completely sure--part of my issues related to using HTTPS on the server instead of HTTP. That could be the reason I had issues on the production server, but not my local or staging box.

Migrating Instances from ColdFusion 8 to ColdFusion 9

Unfortunately, I came back from lunch yesterday to find my laptop was dead. I couldn't get it to load. It was a refurb unit that had served me well enough for three years. I was hoping to get another 6 months out of it; but it is what it is.

This put me in the unfortunate position of needing to set up a new development machine **NOW**. Thankfully, I have a new machine here just waiting to be set up for development. It gives me a slight delay before I have to replace the laptop.

The old machine had CF8 installed in the multi-server mode. I had used the CF8 instance manager to deploy multiple CF8 and CF9 instances of ColdFusion for development purposes. Could I take those instances created in CF8 and somehow use them in CF9 without having to recreate them from scratch? Yes, the answer is yes.

I wrote a bit my experiences moving these same CF8 instances from one machine to another in the past. Here is how I did it:

  1. First I installed Apache. It is my preferred web server. Then I stopped Apache, backed up the config files, and replaced the 'clean' config files with my old config files. This will give me all the info that attaches Apache to the CF Instances and what not.
  2. Then I installed ColdFusion 9; the multi-server edition. During hte install I attached it to my 'clean' config of Apache. I had no idea, when I was doing it, if that was a good idea or not but it worked and the 'old' Apache config seemed to connect up to ColdFusion without any issues. So now I have a working CF Administrator with an instance manager.
  3. Then I used winmerge to compared my old CF8 install directory and the new CF9 install directory. I copied over all my server instances--except for the cfusion one that was created by default. The server instances are located in the servers directory of the install.
  4. Finally, I scoured over all the differences in the winmerge report to figure out how CF was deciding what was an instance and what wasn't. There are two files:
    • lib\wsconfig\
    • lib\servers.xml
    I believe these two files contain all the data for how the CF Instance manager finds the instances. I used winmerge to move all my "old" instances into the new files. I restarted the Macromedia JRun and Macromedia ColdFusion instances, reloaded the admin and all my old 'CF8' instances showed up. Just like magic.

Now all I have to do is create the Windows services for these instances--as I talk about in my other post. Since CF10 is not going to use JRun, I'm not sure I'll be so lucky during the next upgrade.

More Entries

All Content Copyright 2005, 2006, 2007, 2008, 2009 Jeffry Houser. May not be reused without permission
BlogCFC was created by Raymond Camden. This blog is running version