The amazing adventures of Doug Hughes

At Last, MX 7!

Last night I did a little “Cowboy IT” of my own. I upgraded this server from ColdFusion MX 6.1 to 7. All in all, it went rather smoothly, except for two things.

First off, there is appears to be a rather important difference as to how ColdFusion 7 creates stubs for web services. Specifically, my fortune web service simply stopped working from ColdFusion after the upgrade. I could still use it from .NET, but CF kept giving me bizarre errors relating to errors in the Java stub. The strange part about this was that if I simply renamed the fortune.cfc file it would work. However, lots of people use that service, I can’t just change the name!

I ended up stripping out all the public methods and trying to rebuilt it method by method till I could find the part causing the problem. Oddly, when I had only one remote method I still got an error, but it was different from others. Unfortunately, I failed to make note of it. I think it was something like a duplicate file name error from Apache Axis. I spent some time pondering this before I stumbled across the answer to the problem!

My web service is named fortune.cfc. However, it’s <cfcomponent> tag looked like this:

<cfcomponent displayname="Fortune" hint="I am a web services version of the popular BSD/Linux amusement/game Fortune.">
...
</cfcomponent>

On a whim, I decided to change displayname=”Fortune” to displayname=”fortune”. I stopped and restarted ColdFusion and suddenly (and much to my surprise) ColdFusion 7 was able to generate the stub for this web service!

My guess is that if you define the display name, and it’s the same as the CFC’s file name, it needs to be the same case.

I hope this helps someone else. What a pain!

The other issue, which I’m still resolving, relates to Verity but might be specific to how I tried to do the update. I was running on JRun. However, I wanted to be able to use the Enterprise manager in ColdFusion. From what I’ve seen, this only shows up in the default installation of ColdFusion on JRun. Subsequent instances of ColdFusion or instances created from EAR or WAR files do not provide the enterprise manager. So, I tried creating ColdFusion Archives (car files) for each of my server instances. I then uninstalled JRun completely and reinstalled fresh from the ColdFusion 7 installer.

This did give me the enterprise manager, as hoped. However, when I restored the car files to the new instances I had issues with one instance that had been using Verity. The problem is that ColdFusion MX 6.1 collections do not upgrade or are not forward compatible with ColdFusion MX 7 collections. However, MX 7 made a valiant effort to deploy the 6.1 collection anyhow. I received errors relating to deploying the collection. However, it made reference to the collection in the administrator.

Now the collection can’t seem to be easily deleted. I have to jump through hoops do to so. If I do manage to delete it and recreate it using the administration interface I can’t add documents to it. Very odd.

Luckily, it’s only one instance and one collection. I plan to export all the settings from the bad instance (not including verity collections) and create a whole new instance. I’ll then import the good settings from the old instance and point all the sites to that new (and hopefully correctly working) instance. If that works I should be able to recreate the collections and delete the bad instance all together.

It might be a pain, but I’ve got to say, JRun and J2EE are cool.

Comments on: "At Last, MX 7!" (3)

  1. Scott Stroz said:

    Doug – Can’t help but think the Verity thing is from me.

    It actually is not one collection. It is ANY collectoin FarCry creates. This issue is when I try to use the FarCry functionaltiy to update the collectoins.

    Like

  2. Sean Corfield said:

    In CFMX 7, displayname= now has a specific meaning for CFCs used as web services: it allows you to specify the name of the service element (specifically for document style web services – but clearly it also has an impact on non-document style web services too).

    Like

  3. I’d been trying to figure that one out for ages. I didn’t notice any reference to the displayname thing in any of the cfmx documentation.

    works a treat though. thanks!

    Like

Comments are closed.

Tag Cloud

%d bloggers like this: