Oct
30

Finally, after a week of preparations and changes I've switched my DNS entries to HostMySite. I've been on a great host for over 5 years but in order to stay current with the latest version of ColdFusion it has been necessary to find a new provider. After doing a bit of research and talking with other CF developers I chose HostMySite's Linux Builder+ plan. After moving my general site files (and updating some pages therein) I began moving my blog from Greymatter to Ray Camden's excellent BlogCFC. Ray's blog is set up very nicely and was very very easy to install. I had initially installed MovableType but after huge headaches and hours of attempting to import my three years of posts I decided to give BlogCFC a try. Skinning the blog was definitely the most time-consuming. I downloaded the base Aura skin and had a version of my new blog up in no time. After looking through the CSS files for Aura and feeling like the code was a little bloated (lots of unnecessary CSS classes and ID's) I decided to build my own version of the skin.

The basic look of my skin is not unlike other Aura skins out there (see Steven Erat's blog and Ray Camden's blog). However, my skin does not make use of the 4 CSS stylesheets and all the directories that come with Aura. It's much easier to grasp and it's very easy to make changes without getting lost in the CSS. Not being a designer it took me a painful amount of time creating all the image slices and getting everything to line up. And, I'm not done yet. I still have to create a footer graphic to round out the bottom corners. The work was well worth it though and I'm very happy with the new look of the blog (and my new host)! Now, users can subscribe to my various feeds through RSS 1.0 and 2.0 (see the RSS pod in the sidebar to the right). Comment posting and e-mail subscriptions are also now available. All-in-all, I'm excited to have a fresh new blog up and I'm excited about now being on ColdFusion MX 7. With all these changes you'd think it was the new year or something!

Oct
30

This past week, at work, we decided to replace all code using the CFX_Image dll with Doug Hughes Alagad Image Component (AIC). The AIC is highly regarded in the ColdFusion community as one of the best image manipulation utilities available. That it's built in native ColdFusion code without any dependencies on server platform is but one of its strong points. It's also pretty darn robust and chock full of dozens of drawing, resizing, coloring, and other functions. I spent some time putting the AIC into place and have learned a few things about its use. Immediately obvious are some potential threading issues given how instance data is stored in the component. Because the component stores information about read images in the component itself, it's not advisable to create an instance of the CFC in the Application scope (at least, not without some extra work). This is both good and bad. Because it's expensive to create instances of the component it would be nice if you could store one instance in the Application scope and then call methods on that instance anywhere in your application. Without some extra work to serialize access to the component, the potential for two different users to read each others image data (and erroneously write images with that data) is real. Jared Rypka-Hauer, on the Team Macromedia list recommended creating a resource pool made up of several (perhaps hundreds) of instances of the CFC and then single-thread multiple calls to the resource pool via your own management code (perhaps another CFC). This would be fine in most cases but given how memory-intensive the AIC is you would certainly impact server resources.

For our purposes at work I chose to simply create an instance of the component in the variables scope each time I needed to use it. One of our back-end processes involves resizing upwards of 2,000 images at a time. Creating one instance of the AIC before the image processing loop and calling the various methods throughout the body of the loop worked really well. It took approximately 8 minutes (on a very low grade server) to read about 700 images and write 1,400 images. The whole process, as compared with the CFX_Image tag, was slightly slower but with greater functionality and system portability there's no doubt the Alagad Image Component comes out ahead.

Of all the image manipulation tags available I definitely recommend the Alagad Image Component. For $75.00 you won't find anything better.