Hibernate + ColdFusion 9

I just noticed this blog entry Mark Mandel posted about all the recent talk of Hibernate in ColdFusion 9 and the speculation that this will kill off Transfer as a project. He had some of what I thought were very smart things to say on the subject. A friend of mine made the same sort of comment to me the other day.

I wasn't at CFUnited, I hadn't heard about that suggestion, so this was the first I'd heard of it, somebody saying to me (again), "hey ike, get ready to trash all your hard work, 'cause the next version of CF is going to replace it". This has happened to me several times over the years actually. In one or two cases I have actually adopted something that was built into ColdFusion, but it's not usually been the case. Sean Corfield had made a comment once on a mailing list in response to something I'd said about the onTap framework before ColdFusion released the rich-forms features and I haven't adopted those. The new features did however inspire some changes in the onTap framework that made it better and I suspect that might also be true of Hibernate integration.

All of which is entirely aside from the point that if there is a Transfer killer, it's DataFaucet. :P

After Mark's comments about competition, I'm sure he won't mind my playful jabs. :) I actually have watched his CFMeetup presentation. There were one or two things in there that I thought I could work into DataFaucet, although there's a lot in Transfer that at least on the surface I don't care for.

I personally don't find the notion of fetching and storing composed objects within the Transfer Object (or in my case ActiveRecord) to be a really useful idea... It's certainly the way it would be done in Java, but if you've read any of my other articles you likely know by now that I'm a fan of writing to the platform in use, not some other platform that may or may not be underneath the platform in use. And that means writing to the strengths of ColdFusion, which frequently are very different than the strengths of Java. In ColdFusion it's much easier and much more efficient generally speaking to use queries where applicable for things like lists, etc. and from the video it looks like Transfer suggests that you should more frequently work with objects directly for list pages. That to me is maybe good Java, but Java isn't my primary platform and imo it's not good ColdFusion.

So all that being said, you may see some cross-pollination of features from Transfer, but as of yet I'm not entirely sure what that will entail. And I suspect the same might be true of the Hibernate features in CF 9.

Edit 9/19/2008: After spending a bit more time looking at Transfer, I'm pretty certain at this point that I was wrong when I said that Transfer prefers objects over queries for lists of records. Transfer does seem to place emphasis on objects for "many-to-one" relationships (see this blog from Scott Stroz at Alagad), which is not true of the DataFaucet solution. And I'm going to apologize up-front that my response to Scott's article may seem rather catty... I admit I'm biased an opinionated, I just have difficulty with my social skills because of my autism. So I'm open to suggestions of ways to reword that blog in a way that's more suitable. :)

Comments
Sana's Gravatar Hi Isaac,
All I can say that hibernate is totally different animal and I think its not easy for CF developers to grasp the concept and implementation of hibernate.

Secondly hibernate is CF9 feature but I think its long way when every body upgrade to CF9 and also there would be allot learning processing for hibernate.

I hope Transfer and DataFaucet would be great tools for cf developers.
# Posted By Sana | 6/24/08 12:05 AM
Terry Schmitt's Gravatar I think the current crop of ORMs will be around for a while. Wait and see is all I can say about CF/Hibernate integration. While I love CFML. I, too, have never utilized some of the flowery features like charts, ajax, cfforms and so on. I have never found them flexible enough for a real application and always use 3rd party products like Corda Popcharts, ExtJS, Prototype etc.
I've used Transfer and Reactor and my thinking goes back and forth on object vs query. I can't see turning every database hit into an object just for the sake of using an object. The CF query is one of the most powerful features in CFML, why not use it the way it was designed? I am, by no means, against OO in CF, but I think a lot of people read too many Java design pattern books and try to shoe-horn CFML into something that it isn't.
I've been reading up on DataFaucet lately and also trying to get up to speed on J2EE, load balancing, and scaling CF apps. I'm trying to envision something like DataFaucet integrated with something like memcached... Keep up the good work.
# Posted By Terry Schmitt | 6/24/08 10:39 AM
ike's Gravatar Thanks Terry. :) Speaking of memcached, I did have to redraft the caching mechanism for DataFaucet because as I suspected, the original was broken after the migration. Fortunately for me, most of that stuff is generally pretty well encapsulated, so it wasn't a ton of work -- I think I built the new one in an afternoon. Anyway it's in both the repository and the archive download on the DF site which means you should be able to integrate memcached at this point with a custom cache manager. I looked at the couple of projects on RIAForge for integrating memcached although I haven't downloaded either or looked at any of the code yet, but you got me curious about it. If you ask me, I'd take integrated memcached support first over integrated hibernate support in CF9. It seems to me like that would be more versatile & useful to the community as a whole.
# Posted By ike | 6/24/08 4:44 PM
ike's Gravatar incidentally, if you get a chance to look into the other 2 memcached projects on riaforge and are able to put together a custom cachemanager that uses is, I'd love to include that code into the distribution as an option that can be enabled in the DF config tag. :)
# Posted By ike | 6/24/08 4:47 PM
BlogCFC was created by Raymond Camden. This blog is running version 5.5.006. | Protected by Akismet | Blog with WordPress