What I learned at CF.Objective conference
This is a recap of the sessions I went to, partly to organize my notes.
SATURDAY, MARCH 10
Keynote on Mystic and Flex - Tom Jordahl of Adobe
I'm not really into Flex (yet), so here's just a few tidbits. Discussed Mystic and Flex 2. Mystic will be an additional feature for the CF server to facilitate working with Flex. Flex 2 IDE (a plugin for Eclipse) will have some highly desired items such as RDS and Bean generation based on a table.
SQL Abstraction - Isaac Dealey (onTap Framework)
Isaac has built some cool tools for allowing you to get data from your tables without caring which Database you have (MSSQL, MySQL, Oracle, etc.) He posted an article that can explain things much better than I: http://coldfusion.sys-con.com/read/45569.htm
CFCs with Factories - Sean Corfield of Adobe
Code can become more difficult to maintain and objects more difficult to manage if you have createObject (or cfobject or cfinvoke) sprinkled throughout your code. Using a "Factory" to create your objects can clean this up. This follows a couple of the OOP tried and true Design Patterns. While writing a custom factory is possible, he (and others) are using ColdSpring (www.coldspringframework.org). I've tried this out and it is pretty sweet. Another side recommendation Sean made was when creating an object, go ahead and run the init method to avoid having an object be initialized twice unnecessarily (even undesireably). For example, using CF Script: myNewInstance = createObject('componen't,'path.to.my.cfc').init('arguments');
AOP with ColdSpring - Chris Scott
This one was a bit over my head, but sounded like cool stuff. AOP stands for Aspect Oriented Programming. I don't know exactly what that means, but Chris explained a posible implementation where if you have a method in a CFC for which you want to create a log entry each time it is executed, you could use ColdSpring and its AOP capabilities to call an external logging service (cfc) to handle this. This is better than putting the logging code directly into the method because as soon as you have more than one method you want logged, you would have duplicate code.
Object THINK - Simon Horwith
Simon likes to deviate from the 'formal' way of thinking about objects. Based on a lot of object theory and design research that he has done, he prefers to get a full understanding of what a business does and personify objects. He encourages writing the nouns of the business (customer, product, invoice) on an index card and then expanding on what that thing can do. The most recent issue of ColdFusion Developer's Journal explains some of this thinking and also goes into his stance on frameworks in general.
Mach II and ColdSpring - Kurt Wiersma
Kurt has been found that the combination of Mach II and ColdSpring is quite useful. He created a "Starter" application called AppBooster which can be used as a starting point for any new application. It comes with a login, User management and login verification via the session. AppBooster can be used as a MachII/ColdSpring learning tool also. He should be posting this on his blog soon (google Kurt Wiersma).
SUNDAY, MARCH 11
Keynote on ColdFusion in the Enterprise - Hal Helms
Hal discussed ColdFusion and its successes in being used for mission critical applications. He used a marketing analogy, which was interesting as I was a marketing major, for how we should be convincing management that CF is a good fit. I won't elaborate on this part, but Hal also encouraged us developers to put ourselves in management's shoes. The manager is just trying to do what he feels is best for the company (and not get fired). Another great quote Hal said is aimed at CF developers: "CF Programmers need to get out of the webmaster world and into the software engineering world." With that, we will be able to build Enterprise class applications, not just web sites.
Enterprise Reporting - Kurt Wiersman
When CF 7 first came out, I learned about cfdocument and cfreport as possible reporting solutions. What I hadn't heard before was a real world story of how this can work. Kurt has been able to build reports using either cfdocument, the ColdFusion Report Builder, or good old CFML/HTML to meet his companies needs. One part that helped me know what to do about my company's reporting woes is to first evaluate all the reports and determine their usage. This breaks down as follows: Audience-who will see it; Medium-screen, paper, publication, exporting; Frequency-how often it is used; Timing-when it is needing; and User-who will run it (possibly with scheduler).
Objects & Persistance - Sean Corfield
Sean discussed the standard way to get your database to talk to your business objects. Data Access Objects (DAOs) and Gateways seem to be the most accepted way to do this. Coding these can become quite redundant. So Sean also presented on some code generators that can handle this for you. These generators do more than just spit out code for your use, they can change on the fly and handle table relationships and such. More appropriately, these code generators are called Obect Relational Mapping (ORM) tools. Reactor is an up and coming one that Sean and the ColdSpring guys are working to integrate. objectBreeze is another one that just went to version 1.0. There is an article in the latest issue of CFDJ about how to use it (looks pretty easy). One purpose of these ORM tools is to prevent you from having to write any SQL.
Migrating Legacy Apps to CFCs and OOP - Matt Woodward
Matt discussed some things to think about when considering a rewrite on an existing application that is showing its age. He then did a case study on a migration he started a while back and is still in the midst of. As I am currently looking to do this myself, I have to take one his pieces of advice seriously and that is to watch out for the Business' needs over my own geek desires to use the latest, coolest technology.
Frameworks Roundtable - Jared Rypka-Hauer, Peter Farrell, Matt Woodward, Kurt Wiersma, Sean Corfield, Isaac Dealey, Chris Scott & Paul Kenney
There was lots of good advice given from these guys as they fielded questions from the audience. I asked them if I should be afraid of choosing a framework and that framework possibly being deprecated or forgotten about soon after I deploy my application. They said this shouldn't be a concern because they are all open source and maintained by many. Also, if I get an application working on a framework, I can keep that framework code working with that app. Another helpful explanation for me was to categorize all the different stuff falling into the generic 'Framework' term. Fusebox, onTap, Mach II, and Model Glue all help you structure your code into a more maintainable way. ColdSpring, Tartan and Chili Beans (deprecated) help you manage your model (CFCs that do the business work). And Reactor, objectBreeze and ARF are Object Relational Management tools for working with the database. It is possible to use one from each category in conjunction, though it can take some doing to get it working.
Model Management - Chris Scott
Chris gave a good overview of what ColdSpring does and how it can help manage your CFCs, especially those that have dependencies on each other. I am starting some use of ColdSpring myself and really liking it. Again, check out coldspringframework.org.
Quite the long post. I'll try to post some code examples of how I'm using what I learned pretty soon. I just submitted this blog for inclusion on MXNA over the weekend, so we'll see if that drives a little more traffic my way. I had a huge spike after Ray Camden posted link to my entry about porting his Canvas Wiki to Mach II.