The last 2 weeks I have sat down every evening and [re]read through parts of Fusebox's core files, I also had a very energetic discussion with Team Fusebox (more on that some other time). First I have to say Sean put together on hell of a beast in Fusebox 5.5. In some aspects Sean and I have a different coding style so I feel like I would have done a couple of nit picky things differently but overall Fusebox looks to have been very well thought out and put together nicely. My main gripe is the abundant [ab]use of public parameters on the CFCs which sometimes makes it hard for me to track something down, especially since most of the time they are defined for the first time inside one of the methods of an object. Sometimes I get lost in all the parameters that are set but that's just the amount of data Fusebox is dealing with at times. The one thing that I was left without that disappointed me was unit tests. To that point I am working on some unit tests for the core files but I still do not have a good enough handle on all things Fusebox to begin to write good unit tests. The tests I have are mostly checking the skeleton right now (which works ok but I am on my TDD kick right now ;) ). With the small bad I have to say Sean left me with one of the most solid code bases I have ever seen. Some of the stuff he does in Application.cfc are pretty cool and thanks to its nicely done design I've been able to get in and make some additions already. The features I am talking about here are implemented and will be available in the BER I publish this weekend. I want to hear feedback on them, please please please let your voice be heard!
I've not tried to hide my disdain for circuit XML in Fusebox (have no fear it is going no where and will get lovin' when it needs lovin', too many of you people are masochists and like the XML). As a sign of good faith I added a feature to the XML fusebox that had always really bugged me (I'd like feedback on the good/bad side of this change). I've always hated having 15 circuit.xml files open in the editor which lead to the addition to the circuit.xml finding algorithm. Fusebox (in the BER that I plan to push sometime this weekend) will now find alias.xml or alias.xml.cfm in the path specified in Fusebox.xml.
The second feature that I added was something I really wanted to see, and I wanted it at Kroger. Fusebox now supports defining No XML circuits in fusebox.xml. What this means is you do not have to rely on Fusebox's location conventions to leverage No XML circuits. In Kroger our application layout does not match the conventions that Fusebox wanted to impose. I had a long discussion with some friends and colleagues about changing Kroger's application layout vs adding some functionality to Fusebox. In the end I felt it was a feature that would give Fusebox users a nice mesh between configuration and convention.
Like I said I plan to get this stuff into SVN this weekend so anyone interested can start playing with it. I've turned off comments on this entry so as to drive all comments to the Fusebox Group on yahoo, I am doing my best to keep the discussion in one main place.
Friday, September 19, 2008
Saturday, September 13, 2008
SQL Injection Nonsense
I know a whole gobs of blogs have been talking about the SQL injection issues and all the fun stuff recently. I don't generally get into these security discussions as they're really not my focus. Don't get me wrong it's an important subject but I feel like there are plenty of other people out there tooting this horn and presumably know a crap some more than I on the subject. I'll be honest for the last 4+ years I have worked completely inside our firewall on the intranet so security is a bit different for us. One thing I keep finding myself questioning though is how many of us are putting ourselves at risk unnecessarily? I'm not talking about not using cfqueryparam here I am talking about the datasource and the database itself. Is your CF server using an account with the appropriate security level? Lets be honest here 80% of us are using sa or some account with entirely too high of privileges for what it is being used, what a dead brained move. If you are using sa or some other admin level account stop it and you stop half the threat. You don't even need to change code just the data source in the Admin. Even if for some reason your web app needs to control the database at some crazy level create specialized datasources for that section of the application. Datasources that are used on a publicly accessible portions of a website should be restricted as much as possible.
Friday, September 12, 2008
MVCFUG gets to listen to me Rant
With the successful launch of the MVCFUG I am excited to be able to provide content for a local UG. They've asked me to present there next month about Improving Code Quality. Some of you may remember I did a BOF at cfUnited that had a great turn out and this is the presentation that I was going to present at cfDevCon. Unfortunately, cfDevCon had to be canceled but I am excited to share the content stateside with a great group of developers. As an aside this one I think is planned for the evening so folks in Cincinnati should make a trip up, it's just Miamisburg. I am not sure that they are setup to do connect so please don't expect a connect presentation out of it. As with most of my presentations this one really focuses on how we can work together and produce high quality code. We'll most likely focus on peer design and peer reviews. When I say code quality I am not talking about using a structure or queryparam (that is not what a code review is for people!). Really I am not even talking about using CFCs (correctly or otherwise), though they can play into quality. I am talking about how we can work together to create maintainable software that has high fidelity. Talking about code quality is a very passionate subject and I can't wait to share my experiences with the Miami Valley folks!
Monday, September 08, 2008
Fusebox 5.5 Documentation
I know a lot of folks have asked for more documentation for Fusebox 5.5. This morning it occurred to me that maybe, like myself at one point many months ago, folks are not aware of Sean's excellent release notes. I have to say Sean did a great job with his release notes for 5.5 and 5.5.1 (missing). These 2 PDFs that may not be indexed by google which may be why not many people are aware if them. I will try to get some of this content copied out and into the wiki over the upcoming weeks but if you have not read these docs please do so. I really think they do a good job covering Fusebox 5.5 functionality. Also please remember Jeff has now released a new book for Fusebox!
Wednesday, September 03, 2008
bFusion Marterials
I've spent a lot of time working through the hands on work for my TDD presentation at bFusion. Though the result may not seem like it as there are no materials (files) that you will need for the presentation. You will still want everything installed and running (coldfusion, eclipse, mxUnit) but you will need no additional files from me. You see I wanted a nontrivial example to work through but the problem with this is even if I did not speak at all 1.5 hours is not enough time to do a non trivial example. Besides TDD is much less about writing a test (anyone can do that) and much more the thought process. So inside of throwing you to the wolves to work hands on I will present and answer questions for around 30-40 (depends on ???s) minutes and the remainder of the time we work together to solve as much of the non trivial problem as we can. This will everyone understand what types of things we should think about when writing tests and how to work TDD into a real project. The reason the presentation jumped in amount of time is during the presentation we'll be dropping into the IDE a quite a few times to work through things together. I hope everyone will work along with me as you will get much more out of the session if you work along with me, as well as provide feedback!
Tuesday, September 02, 2008
Fusebox in Java??
A couple of weekends ago I stepped into my Java developer shoes and attended No Fluff Just Stuff, think cf.Objective() in attendance size, cfUnited Express in local feeling, and cfUnited (or SOTR) for quality of speakers. I wrote up the majority of the entry during that conference. Instead of publishing it at that time I decided to sit on it for a bit before rereading my thoughts and posting this entry. At NFJS Neil Ford talked about polyglot programming, something I myself have joined in about in the past. If you will recall polyglot programming has morphed into this thought process of using the appropriate language to complete a task. The JVM has become a very powerful platform, now supporting some 200+ languages. Most of these languages can interact with one another at some level, if not directly then they can use the the Java level. While CFML happens to be my preferred language to write most of my applications in I have to wonder should frameworks be written in CFML?
Historically we were bound to strictly CFML, putting any part of a framework for CFML apps in Java would require putting the class on the classpath, not so shared hosting friendly. Well we have all progressed and learned a thing or 2 about Java and this traditional thought process needs to evolve some. Thanks to Mark Mandel and some of his crazy cool java class loader work, even if you don't know much about class loaders, we are not bound to our traditional thoughts about how we can load java classes. We can now easily load java classes after server start up from places other than the predefined classpaths. Armed with this knowledge I can now objectively ask, should Fusebox be written in CFML or should it be written in Java (or groovy or anything else that I could consume from CFML)? Even weeks later, presumably after all the Java Kool Aid has left me system, I still am leaning towards Fuseox should be written in Java. Maybe should is a bit too string of a word there, Fusebox could benefit from being implemented, at least in part, in Java. This is not a proclamation that I am going to rewrite Fusebox into Java, remember I said I was going to think out loud when it came to Fusebox development, but I really am leaning towards writing parts of Fusebox in Java.
Historically we were bound to strictly CFML, putting any part of a framework for CFML apps in Java would require putting the class on the classpath, not so shared hosting friendly. Well we have all progressed and learned a thing or 2 about Java and this traditional thought process needs to evolve some. Thanks to Mark Mandel and some of his crazy cool java class loader work, even if you don't know much about class loaders, we are not bound to our traditional thoughts about how we can load java classes. We can now easily load java classes after server start up from places other than the predefined classpaths. Armed with this knowledge I can now objectively ask, should Fusebox be written in CFML or should it be written in Java (or groovy or anything else that I could consume from CFML)? Even weeks later, presumably after all the Java Kool Aid has left me system, I still am leaning towards Fuseox should be written in Java. Maybe should is a bit too string of a word there, Fusebox could benefit from being implemented, at least in part, in Java. This is not a proclamation that I am going to rewrite Fusebox into Java, remember I said I was going to think out loud when it came to Fusebox development, but I really am leaning towards writing parts of Fusebox in Java.
New CF UG in Ohio!
I was utlra stoked to see Lance tweet about his latest blog entry detailing the launch of the Miami Valley CF Usergroup. Congrats to Aaron and Lance for this accomplishment. The Greater Dayton area has some extraordinary talent and will be well served to have a proper usegroup up there. Being a Dayton native I am glad to see that market continue to grow and prosper, hell may someday I will get to move back up into that market. Until that happens I need to get off my ass and follow suite and get the Cincinnati UG up and running, Kroger has one but I've never committed to doing an external one. Congrats again gentlemen, you know I am always happy to come up and present and I will certainly make an effort to attend as much as possible, O'neil's office isn't too terribly far away from me.
Thursday, August 28, 2008
Open Source Sorta Kinda Rocks
I've been pretty busy recently not only at work but I've picked up enough stuff to keep me plenty busy outside of work with my involvement in cfConversations, mxUnit stuff, Fusebox and OpenBD. In all honesty this all has taken a bit of a toll on my blogging. I feel like I had been doing pretty well (or at least improving) with my blogging up until a little after cfUnited. As I look through my recent posts I realize I have given any blog time to one of my first public involvements, OpenBD.
The buzz has settled and we are all still standing! Adobe still exists, the CFML community as strong (dare I say stronger than ever), and we are slowly growing our community with more and more developers from other platforms with interest in CFML (wether it OpenBD or Adobe or even the future Railo OS effort). We (OpenBD) never made a big deal about it but Kirk Pepperdine a Java Champion and Server tuning wizard joined OpenBD Steering committee a couple of months back.
I think OpenBD still has a ways to go before folks in the CF community will begin to adopt it fully for use in projects. This is not to even suggest it is not a solid product as is (really it is an awesome product as it stands) but it does lack a couple of things that I feel are important for folks in the CF community. I think we'll see more adoption once we establish an official version number (and version schema/road map) and public facing documentation, I swear a wiki has been on the way for months now. I also am under the impression people are still a little weary about this whole WAR deployment, something Adobe's ColdFusion has done a very good job shielding us from for years now. Oh and finally that whole lack of a GUI for the admin might scare off some folks as well. I can happily say that folks are in one way or another working on all of the above. This is exactly why open source sorta kinda rocks. I think most people would agree Matt Woodward is an awesome developer and thanks to OpenBD you get his code running in your enterprise for the exact price of nothing, though a thanks is always appreciated. Alan Williamson is an elite, recognized, Java developer and you get his work, again, free!
If you want proof positive that OS rocks check out this thread on the OpenBD mailing list. Suggestion to alpha released jar in something like <72 hours. You just will not, generally, see this in a commercial product. Really you should not expect it since Adobe has big incentives to hide their new features until release. Thanks to the completely open nature of Open Source projects there is nothing to hide. If we are working on something I can guarantee that you, and everyone else, will know about it right quick. No need to be an exclusive beta or alpha tester, just drop by in your spare time and ask "Hey whats up?" Some enthusiastic user or developer will usually be more than happy to point something out.
The buzz has settled and we are all still standing! Adobe still exists, the CFML community as strong (dare I say stronger than ever), and we are slowly growing our community with more and more developers from other platforms with interest in CFML (wether it OpenBD or Adobe or even the future Railo OS effort). We (OpenBD) never made a big deal about it but Kirk Pepperdine a Java Champion and Server tuning wizard joined OpenBD Steering committee a couple of months back.
I think OpenBD still has a ways to go before folks in the CF community will begin to adopt it fully for use in projects. This is not to even suggest it is not a solid product as is (really it is an awesome product as it stands) but it does lack a couple of things that I feel are important for folks in the CF community. I think we'll see more adoption once we establish an official version number (and version schema/road map) and public facing documentation, I swear a wiki has been on the way for months now. I also am under the impression people are still a little weary about this whole WAR deployment, something Adobe's ColdFusion has done a very good job shielding us from for years now. Oh and finally that whole lack of a GUI for the admin might scare off some folks as well. I can happily say that folks are in one way or another working on all of the above. This is exactly why open source sorta kinda rocks. I think most people would agree Matt Woodward is an awesome developer and thanks to OpenBD you get his code running in your enterprise for the exact price of nothing, though a thanks is always appreciated. Alan Williamson is an elite, recognized, Java developer and you get his work, again, free!
If you want proof positive that OS rocks check out this thread on the OpenBD mailing list. Suggestion to alpha released jar in something like <72 hours. You just will not, generally, see this in a commercial product. Really you should not expect it since Adobe has big incentives to hide their new features until release. Thanks to the completely open nature of Open Source projects there is nothing to hide. If we are working on something I can guarantee that you, and everyone else, will know about it right quick. No need to be an exclusive beta or alpha tester, just drop by in your spare time and ask "Hey whats up?" Some enthusiastic user or developer will usually be more than happy to point something out.
Wednesday, August 20, 2008
CodlFusion 9 Feature Request
I like Mark's java Loader it's nice but I feels hacky using it. Not saying anything in it is wrong or otherwise not grade A. I just feel like I am hacking something together using it. It'd be nice if this was just built into the engine, I was thinking something like createObject("java","com.package.Class",ClassLoader). This would allow ColdFusion to search one additional classloader that I create, presumably with UrlClassloader. Now I understand that this one might be odd since, as far as I recall, this would be the first you'd ever feed a Java object into a CF method so maybe we could just pass in a URI string, createObject("java","com.package.Class","/path/to/class.class")? Anyrate my whole point here is we are seeing more and more integration with Java and there is, obviously, a need for folks to load in Jars at runtime*. Many do not have access or know how to add jars in the defined classpaths, or add classpaths to jars.
* Yes I know Shared hosts would most likely not like this but the fact of the matter is we can already do it, and Mark has made it super easy. So since we can do it we should just add it to the language instead of some external CFC.
* Yes I know Shared hosts would most likely not like this but the fact of the matter is we can already do it, and Mark has made it super easy. So since we can do it we should just add it to the language instead of some external CFC.
Monday, August 18, 2008
Hello Guangzhou
I was checking out my traffic this morning and saw some folks from China had visited. I was curious where in China so I drilled down to see more details. I was thrilled when I saw I had visitors from Guangzhou. Why you ask? Well a friend of mine, well she would say co-worker, is from your Guangzhou, which I still struggle to pronounce correctly. I thought it was cool to see someone from her home town checking out my blog! I think China is a very interesting country and the culture there is fascinating, its very similar to Americans on some levels then miles away on others. Maybe someday I will get the opportunity to visit China so I can experience it myself. Before I do that I need to get a lot better at Chinese, maybe I'll pick up that software they advertise on TV. Any rate from me to you and everyone else in China, Australia, Canada, France, Germany, and many other foreign places I can only hope to visit some time in the future hello and thanks for stopping by!
Thursday, August 14, 2008
Speaking at bFusion
Bob Flynn and is once again hosting bFlex and this year has added bFusion! bFusion is an awesome 1 day FREE(!!) event at Indiana University (Bloomington Indiana) followed by a 1 day FREE event for Flex. I won't get into the sales pitch just check out the site. I do want to pimp my 2 sessions though both of which are very near and dear to me. First is Open Source CFML Engines and second being Headfirst TDD.
In my Open Source CFML session we'll explore the open source business model and take a deep dive into how open source CFML engines will help shape the future of CFML development. There is a lot more to Open Source than just the free cost aspect we'll explore this for a brief while. We'll also discuss the differences between Platform and language. I think its just as important to recognize the value of ColdFusion as it is to see the value in CFML. At the end of the session you'll walk away armed with the knowledge you need to make a conscious well informed decision if open source CFML is the right option for you!
My second session, Head First TDD, is pretty much what the title describes it to be. We'll be diving head first into how to start developing with Tests in mind. The cool part is the Head First TDD will be hands on. I won't tell you how you should do TDD you will follow me and work with others and PRACTICE TDD. In the 1.5 hour session there might MIGHT be 20 minutes worth of presentation the remainder of the time will be used to explore TDD together with, hopefully, non-trivial examples. Since this is hands-on and interactive you'll need ColdFusion (or Railo should work), Eclipse, cfEclipse and mxUnit installed. If you'd rather you can just use pulse and get my profile, which I have talked about before. You'll still need to install a CFML engine and have mxUnit's CFML code downloaded and preferably running in ColdFusion. You'll also need an open mind and bring a little extrovert along b/c you will be working with others! You'll also need to download some CF files for the hands on but the examples I have are very boring and I am trying to come up with new ones, ones I have not finished yet. Most likely that will be done the week of the bFusion as I procrastinate and have a lot on my plate. I'll post them as son as I am happy with them.
Welp that's all I have to say for bFusion, I can't wait to see you all there!
In my Open Source CFML session we'll explore the open source business model and take a deep dive into how open source CFML engines will help shape the future of CFML development. There is a lot more to Open Source than just the free cost aspect we'll explore this for a brief while. We'll also discuss the differences between Platform and language. I think its just as important to recognize the value of ColdFusion as it is to see the value in CFML. At the end of the session you'll walk away armed with the knowledge you need to make a conscious well informed decision if open source CFML is the right option for you!
My second session, Head First TDD, is pretty much what the title describes it to be. We'll be diving head first into how to start developing with Tests in mind. The cool part is the Head First TDD will be hands on. I won't tell you how you should do TDD you will follow me and work with others and PRACTICE TDD. In the 1.5 hour session there might MIGHT be 20 minutes worth of presentation the remainder of the time will be used to explore TDD together with, hopefully, non-trivial examples. Since this is hands-on and interactive you'll need ColdFusion (or Railo should work), Eclipse, cfEclipse and mxUnit installed. If you'd rather you can just use pulse and get my profile, which I have talked about before. You'll still need to install a CFML engine and have mxUnit's CFML code downloaded and preferably running in ColdFusion. You'll also need an open mind and bring a little extrovert along b/c you will be working with others! You'll also need to download some CF files for the hands on but the examples I have are very boring and I am trying to come up with new ones, ones I have not finished yet. Most likely that will be done the week of the bFusion as I procrastinate and have a lot on my plate. I'll post them as son as I am happy with them.
Welp that's all I have to say for bFusion, I can't wait to see you all there!
Labels:
bFusion,
CFML,
CFML conferences,
Open Bluedragon,
Presentations,
TDD
Eclipse Plugin for Fusebox (re: Marc Esher's Comment)
Marc Esher, someone I've grown to call friend over the past few months, left a question in my post yesterday inquiring if Kroger would be donating an eclipse plugin for Fusebox. What Marc knows but others do not is we have built a plugin at Kroger to help kick start project start up. The plugin is a fantastic help to driving consistency and help get a project's code base off on the right foot. The short answer to Marc is no. But I didn't want to leave that sort of comment in my comment trail as that's the short answer. The longer answer goes something like this.
The plugin we have inside Kroger is pretty Kroger specific and reaches far beyond the boundaries of what Fusebox should offer/dictate, in my opinion. Beyond that it is mixed and jumbled up with a large amount of Java web app generation as well. There is also the added complexity of competitive advantage that might keep me from being able to release it. I have not asked so I am not sure where that would take me at this point. All in all the plugin would force way too many things on developers and most would probably find it's restrictions more problematic than it is worth. That being said the concept of the plugin is rather nice and I think I maybe have even mentioned to Marc at one point about making a plugin available. It would not be the Kroger plugin but instead a separate one that I build with lessons learned from inside Kroger. In fact as I think about it what I'd really like is to create a plugin that allows additions to be added, so I can use it internally as the core/seed to Kroger's plugin and externaly folks can use it as the core for Fusebox project creation or Model-Glue generation. In all honesty the plugin does little more than what a nicely written ANT task can do, it just feels cleaner and has a slightly nicer flow to it inside Eclipse. At the end of the day I am one person though and I have to make a decision on what is worked on. Personally, as I said before, I think Fusebox itself is in a happy place right now, it is stable and has reasonably good functionality. So chances are I'll probably work on things like this before picking up the core and flopping it around too much. In short no Marc Kroger's plugin as it is today will not ever be released. After some refactoring some of it, it might be release. There's still the the whole getting permission to do it that may or may not work out.
The plugin we have inside Kroger is pretty Kroger specific and reaches far beyond the boundaries of what Fusebox should offer/dictate, in my opinion. Beyond that it is mixed and jumbled up with a large amount of Java web app generation as well. There is also the added complexity of competitive advantage that might keep me from being able to release it. I have not asked so I am not sure where that would take me at this point. All in all the plugin would force way too many things on developers and most would probably find it's restrictions more problematic than it is worth. That being said the concept of the plugin is rather nice and I think I maybe have even mentioned to Marc at one point about making a plugin available. It would not be the Kroger plugin but instead a separate one that I build with lessons learned from inside Kroger. In fact as I think about it what I'd really like is to create a plugin that allows additions to be added, so I can use it internally as the core/seed to Kroger's plugin and externaly folks can use it as the core for Fusebox project creation or Model-Glue generation. In all honesty the plugin does little more than what a nicely written ANT task can do, it just feels cleaner and has a slightly nicer flow to it inside Eclipse. At the end of the day I am one person though and I have to make a decision on what is worked on. Personally, as I said before, I think Fusebox itself is in a happy place right now, it is stable and has reasonably good functionality. So chances are I'll probably work on things like this before picking up the core and flopping it around too much. In short no Marc Kroger's plugin as it is today will not ever be released. After some refactoring some of it, it might be release. There's still the the whole getting permission to do it that may or may not work out.
Wednesday, August 13, 2008
Hello Team Fusebox
I've been very busy lately with many projects so my blog has been quiet, though I hope Bill Shelton, myself and Marc Esher (among others) can pimp some of this stuff we are working on soon. I did want to take a minute to make mention of the announcement that was made in the cfConversation's round table. It's now official, I am the new developer in charge of the Fusebox core files. Check out the announcement for my brief statement, also check Sean's blog (like you haven't already). Expect me to think out loud a lot on my blog about new features and changes to Fusebox in the future. I do want to thank Sean for entrusting me with the core as well as his kind words, I appreciate the opportunity.
In all honesty Fusebox is in a happy spot right now and aside from bug fixes I am not planning on touching the core much right away. I've heard some rumblings about getting full support for Fusebox 3 and I'd relly like to hear why, and see how many want this. Over time as I get more comfortable with the core files I might try to achieve full Fusebox 3 compatibility but that will take time. Intially I think I am more interested in experimenting with speeding up the core, small enhancements to the no XML features, and providing more definition to layouts (more on this soon this is very much an incomplete thought). So what do you hate about Fusebox?
In all honesty Fusebox is in a happy spot right now and aside from bug fixes I am not planning on touching the core much right away. I've heard some rumblings about getting full support for Fusebox 3 and I'd relly like to hear why, and see how many want this. Over time as I get more comfortable with the core files I might try to achieve full Fusebox 3 compatibility but that will take time. Intially I think I am more interested in experimenting with speeding up the core, small enhancements to the no XML features, and providing more definition to layouts (more on this soon this is very much an incomplete thought). So what do you hate about Fusebox?
Wednesday, July 23, 2008
ColdFusion 9: Server.cfc
I have been pretty quiet about ColdFusion 9, aside from a few comments here and there. I wanted to take a moment to comment on Server.cfc. I'll be blunt and say that in it's current described form I think it will be useless. First let me describe Server.cfc. Server.cfc will provide users the ability to hook into the server start up and shut down events. This will be done by creating a Server.cfc. With this you can now react to onServerStart and onServerEnd.
Sounds promising right? Here's the problem, you can have 1, yes 1, Server.cfc per ColdFusion instance. How many of us deploy 1 application per ColdFusion instance? I know we certainly do not do this, heck we generally deploy 30+ apps to one CF instance. So now if I want each application to be able to do something at start up I have to constantly add functionality to Server.cfc for each application. This seems like a monumental mistake. I'd rather see the server hooks added to Application.cfc and the server scan for Application.cfc files on start up. ColdFusion has come so far to make application self sufficient (mappings, session control, settings override) making one Server.cfc would be a huge step backwards if you ask me.
Sounds promising right? Here's the problem, you can have 1, yes 1, Server.cfc per ColdFusion instance. How many of us deploy 1 application per ColdFusion instance? I know we certainly do not do this, heck we generally deploy 30+ apps to one CF instance. So now if I want each application to be able to do something at start up I have to constantly add functionality to Server.cfc for each application. This seems like a monumental mistake. I'd rather see the server hooks added to Application.cfc and the server scan for Application.cfc files on start up. ColdFusion has come so far to make application self sufficient (mappings, session control, settings override) making one Server.cfc would be a huge step backwards if you ask me.
Tuesday, July 15, 2008
Improve Code Quality: Peer Design
As I work on my presentations I enjoy sharing some of my thoughts along the way. This will be the first of a series of entries that talk about concepts I plan to cover in my presentations. This is mostly a practice of thinking out loud but I think, or maybe hope, they will make a good series of blog entries. Of course, my opinions might change as I collect more and more empirical data, I'm very pragmatic, but I just have to share this knowledge pent up in my head!
What I am about to say may well change the way you think. You might think I am am a blooming idiot for saying it but I hope it helps folks improve their code's quality. Unit test do not improve your code's quality. Pause for a second and let that sink in, unit tests do not improve your code quality. They measure and verify code quality but they themselves do not improve the quality of your code. Think about it, running unit tests over and over again will not improve code's quality. I'm not intending to undervalue unit tests but it is important to realize unit tests improve the application's observed quality by ensuring properly functioning code. Unit tests do not improve your code's quality and more importantly maintainability.
Once you come to accept this fact the question you may be asking yourself is how does one improve the code's quality? Coding standards provide a good quality baseline and may serve to enforce some code quality, TDD can help improve the code quality (a node to unit tests), code reviews could certainly help improve quality, and design up front might help code quality as well. The truth is we all have different techniques to improve the quality of our code and I will discuss each one of the aforementioned topics in the future, and in my presentation.
Today I wanted to spend some time discussing peer application design. XP advocates may be keen to note I left off peer, or pair, programming from the list techniques to improve code quality. I did this with good reason, I do not like it. In my experience it is a waste of a developer, I'm not saying it is a bad technique for everyone but I am not an advocate. The reason for my lack of enthusiasm towards peer programming is I favor peer design. In my experience peer programming really turns into peer design only with lots of code being written and rewritten. Peer application design is when a group of developers/architects, not necessarily limited to only the developers of the system, have a design burn down of how the domain(s) should be modeled. It certainly does not need to be limited to the domain(s) but since at Kroger we have a fairly standard framework stack most of the design discusses focus in the domain modeling and not other aspects of an application. Peer design forces us to use our whole brain as we must first internalize our rationals then verbalize, and often times defend, our rationale with others. At the same time, or near same time, we are internalizing others' concepts and mapping them to our own. Peer design has the added benefit of cross training, since we are including peers that are not planned developers on the system in design. Peer designs, just like their big brother JADs, do not generally just happen; they need coordinated and a strong facilitator ensuring the flow and guiding decisions in the correct direction. This is not to say you can not do a quick peer design with one other person at the bar on a Friday night but generally they are slightly more organized than that! Generally the output of a peer design session(s) is some sort of map for development. The map could be as simple as a cave drawing on a bar napkin or as sophisticated as a set UML diagrams. The diagrams, whatever form they come in, are much easier to change and morph than large chunks of code that you will get with peer programming. In a future entry I will talk about code reviews these diagrams can be very important in code reviews.
What I am about to say may well change the way you think. You might think I am am a blooming idiot for saying it but I hope it helps folks improve their code's quality. Unit test do not improve your code's quality. Pause for a second and let that sink in, unit tests do not improve your code quality. They measure and verify code quality but they themselves do not improve the quality of your code. Think about it, running unit tests over and over again will not improve code's quality. I'm not intending to undervalue unit tests but it is important to realize unit tests improve the application's observed quality by ensuring properly functioning code. Unit tests do not improve your code's quality and more importantly maintainability.
Once you come to accept this fact the question you may be asking yourself is how does one improve the code's quality? Coding standards provide a good quality baseline and may serve to enforce some code quality, TDD can help improve the code quality (a node to unit tests), code reviews could certainly help improve quality, and design up front might help code quality as well. The truth is we all have different techniques to improve the quality of our code and I will discuss each one of the aforementioned topics in the future, and in my presentation.
Today I wanted to spend some time discussing peer application design. XP advocates may be keen to note I left off peer, or pair, programming from the list techniques to improve code quality. I did this with good reason, I do not like it. In my experience it is a waste of a developer, I'm not saying it is a bad technique for everyone but I am not an advocate. The reason for my lack of enthusiasm towards peer programming is I favor peer design. In my experience peer programming really turns into peer design only with lots of code being written and rewritten. Peer application design is when a group of developers/architects, not necessarily limited to only the developers of the system, have a design burn down of how the domain(s) should be modeled. It certainly does not need to be limited to the domain(s) but since at Kroger we have a fairly standard framework stack most of the design discusses focus in the domain modeling and not other aspects of an application. Peer design forces us to use our whole brain as we must first internalize our rationals then verbalize, and often times defend, our rationale with others. At the same time, or near same time, we are internalizing others' concepts and mapping them to our own. Peer design has the added benefit of cross training, since we are including peers that are not planned developers on the system in design. Peer designs, just like their big brother JADs, do not generally just happen; they need coordinated and a strong facilitator ensuring the flow and guiding decisions in the correct direction. This is not to say you can not do a quick peer design with one other person at the bar on a Friday night but generally they are slightly more organized than that! Generally the output of a peer design session(s) is some sort of map for development. The map could be as simple as a cave drawing on a bar napkin or as sophisticated as a set UML diagrams. The diagrams, whatever form they come in, are much easier to change and morph than large chunks of code that you will get with peer programming. In a future entry I will talk about code reviews these diagrams can be very important in code reviews.
Labels:
Code Quality,
pair programming,
Peer design,
unit tests
Friday, July 11, 2008
Hello Adobe Feeds!
I'm glad to get aggregated by MXNA err no Adobe feeds. Hopefully it will expose the blog to some new readership! Being on the Steering Commitee for Open BlueDargon I was thankful to see Adobe still pick me up. I love ColdFusion and I love CFML even more, I think there is room for both open source and commercial, though I wish Adobe would open source ColdFusion I suppose we can't have everything. Right before Adobe Feeds started to aggregate my blog I had an excellent post about the cost of ColdFusion and justifications for that cost. Some have complained about my misleading title but it really is all about how ColdFusion's platform IS worth the price, for some people.
Wednesday, July 09, 2008
ColdFusion Costs too Much
That's a pretty common phrase I hear from folks looking at ColdFusion for the first time. Even scarier I hear it from folks inside the community! Don't get me wrong I love open source and I think there is plenty of room for open source CFML engines/platforms but when it comes down to it ColdFusion's platform for what it offers is a great deal. I get tired of hearing CFML developers tout the RAD of ColdFusion this used to be an okay mostly valid sell but the market has changed yet CFML developers montra hasn't. With a good framework and IDE Java can be pretty RAD these days, besides no one has ever quantfiably proved how much faster ColdFusion, or CFML, really is for development. What follows is an exceprt of a response I sent to a certain "journalist" when confronted about Open Bluedragon, he opened stating ColdFusion's (Standard) price at a mere 1300 was "unbeleivable":
... I'll be the first one to pimp the open source offerings but I also think there are some misconceptions of costs for ColdFusion. If you consider what the Adobe ColdFusion platform offers this [$1300 price tag] is pretty reasonable. What you or anyone needs to ask themselves, especially now with other CFML engines is, "Does the ColdFusion Platform offer me the features I need for the cost?" It seems more and more folks answer no to this but let's think about this for a second. Can Java produce a PDF? Certainly. You can use Java libraries and generate a PDF just fine. Without a bit of work though and a couple layers of abstraction generating an HTML equivelent and a PDF is tedious and can be costly when supporting an app long term. ColdFusion offers you a very simple and elegant way of generating a PDF based off purely the HTML you are already generating. Any pure Java shop can do this too but they need to either modify some open source HTML parses, write thier own, or purchase icesoft's parser (cost: nearly on par w/Adobe's ColdFusion). So with this feature alone all costs, never mind productivity gains of CFML, are nearly negated. Also consider JMS integration. Once again I could develop a nice abstraction layer in Java no problem but then my team is responsible for integration testing, regression testing, and support for this abstraction layer. Not nearly the same if I just use ColdFusion and it's JMS & ActiveMQ integration points. Testing is a real cost and relying on a commercial product is a huge cost saver. A final example to consider is ajax. Have you ever looked at how much a pain it is to refactor from ExtJS 1.0 -> X.X, or jQuery with the UI widgets? The api for ExtJs (and other js libraries) constantly changes and backwards compatibility is becoming a cost barrier to upgrading on large applications. By using ColdFusion's ajax tags you never have to pay a developer to upgrade your codebase to work with the latest version of ExtJS. Adobe is taking care of that for you behind the scenes. Now lets bring this full circle, these are only 3 examples I thought of off the top of my head, there are numerous other cost saving and value adds in the ColdFusion platform so the question really is are these worth it to you? Maybe they are (we certainly take advantage of some of these at my company) maybe they are not. If all you are generally interested in CFML and not the ColdFusion platform, great there are some awesome alternatives now through some open source offerings like OpenBD, Railo and, to a lesser extent, Smith Project. Each OS offering offers their own platform stuff, Open BD for example has a plugin for JMS. Railo, for example, has some very cool integration with Amazon's S3. ... ColdFusion's price point is very valid in many instances for many folks. I am an advocate for open source CFML, no doubt, but I am also an advocate for ColdFusion as it has solved many problems for the company I work for and done it at a huge cost savings.Hopefully this spurs some good discussion and ideas on how ColdFusion is a money saver and not just from a RAD standpoint.
Labels:
CFML,
ColdFusion,
cost,
Open Bluedragon,
Railo
Saturday, July 05, 2008
Pulse2 now with mxUnit
In the past I've blogged about Pulse2 and I have to say it really has grown on me over the previous month or so that I have been using it. I've decided the $6/month is worth the investment as it does save me time and hassle as well as preconfiguring some of the "extra" plug-ins. On the free side though Pulse2's catalog has grown and that includes listening to my previous post and adding mxUnit for all the CFML developers out there! Finally, with this plug-in added I have posted a public profile for anyone that wants to give eclipse a try but have been intimidated by eclipse setup. Check out Pulse2 and use my public profile. Everything you'll want is packaged in there (add Aptana with a freelance account for an ever better development experience). Pulse2 is an awesome tool and something I definitely plan to demo very briefly in my Be Lazy, Use Ant session at cfdevcon. Don't wait for me to demo it though it is dog simple check it out today:
Sunday, June 29, 2008
Speaking at cfDevCon
Its an odd place to start my presentation tour (or I hope it becomes a tour) but I plan on submitting presentations to many conferences moving forward and cfDevCon will be my first presentation stop, though I did lead a BOF at cfunited. My topics, at cfDevCon, will not get you any further along with using your favorite framework and chances are you won't see a whole bunch of cool CFML code snippets either. I figure there are plenty others out there that can do that better than me, maybe in the future I will consider some of those topics. Instead I'll enjoy talking about topics that are applicable across languages, and really thats where my core focus lies these days. In my current role my programming has taken a back seat to my mentoring and training and honestly I spend some of my time with projects that are not even CFML based projects. Many of the concepts I will be presenting on are 100% applicable there too!
My first session will focus on automation, I am all about being lazy and ANT is a perfect way to enable my laziness. This session first started out as setting up a developer IDE and I quickly learned that each person has thier own way of doing things and trying to show just one way of doing it will leave attendees with only a specific solution that works well for me and my company. Instead I plan to focus more on how to use ANT as a tool to not only automate redundant tasks like builds and deploys, but how it can be in integral part of your daily development life cycle. We'll cover things like test driven development and working with mxUnit's ant tasks. We'll touch on how to attach builders to eclipse projects, how to write ANT tasks to run tests, and, inspired by Marc Esher, a good overview of ANT's general syntax. There is a lot of content to cover and it will be fast paced and example heavy. We'll dip into CFML for a short bit to show off mxUnit but most of the examples will be ANT scripts!
The second presentation (yep I have 2 at cfDevcon) will be all about improving code quality. We'll spend a good amount of time talking about code reviews, the different types, how to introduce them in your company and how to be success with conducting code reviews. Code reviews are only one aspect of quality improvement, additionally we'll take a look at mentoring (and how mentoring and code reviews intersect) and JAD sessions. Improving quality is 100% language agnostic, if you have Flex, Java, CFML or .Net background come and check it out, everyone can learn something. If you are already successful with code reviews or mentoring come and share your ideas we'll have plenty discussion points so everyone can share! I'm really looking forward to sharing my success and failures with folks through my presentations, if anyone ever has topics they would like covered let me know I am always looking for other ideas for exciting topics to explore.
My first session will focus on automation, I am all about being lazy and ANT is a perfect way to enable my laziness. This session first started out as setting up a developer IDE and I quickly learned that each person has thier own way of doing things and trying to show just one way of doing it will leave attendees with only a specific solution that works well for me and my company. Instead I plan to focus more on how to use ANT as a tool to not only automate redundant tasks like builds and deploys, but how it can be in integral part of your daily development life cycle. We'll cover things like test driven development and working with mxUnit's ant tasks. We'll touch on how to attach builders to eclipse projects, how to write ANT tasks to run tests, and, inspired by Marc Esher, a good overview of ANT's general syntax. There is a lot of content to cover and it will be fast paced and example heavy. We'll dip into CFML for a short bit to show off mxUnit but most of the examples will be ANT scripts!
The second presentation (yep I have 2 at cfDevcon) will be all about improving code quality. We'll spend a good amount of time talking about code reviews, the different types, how to introduce them in your company and how to be success with conducting code reviews. Code reviews are only one aspect of quality improvement, additionally we'll take a look at mentoring (and how mentoring and code reviews intersect) and JAD sessions. Improving quality is 100% language agnostic, if you have Flex, Java, CFML or .Net background come and check it out, everyone can learn something. If you are already successful with code reviews or mentoring come and share your ideas we'll have plenty discussion points so everyone can share! I'm really looking forward to sharing my success and failures with folks through my presentations, if anyone ever has topics they would like covered let me know I am always looking for other ideas for exciting topics to explore.
Labels:
ANT,
cfDevCon,
CFML conferences,
code review,
sessions
Friday, June 20, 2008
cfUnited BoF
I wanted to thank everyone that attended my BOF at cfunited. I had a great time sharing my experiences and leading a GREAT conversation with all of my peers. The BOF was only a success thanks to the endless participation from the audience. If you enjoyed the BOF you might be interested to know I have a tentative plan to present this type of material at some conferences in the future (maybe even cfunited 09???). Nothing for sure yet but I am working on the possibility. As promised here is the mind map. I will try to capture some of the conversation and more on this Mind map in future posts, maybe when I am running on more than 4.5 hours of sleep!!
Subscribe to:
Posts (Atom)
