As I have seen more and more in our industry, the call for modularity has surpassed the original intent. In far past, too many applications were to huge, hard to read, and were using similar code, that could have been re-used, and save some time.
There is a lot of common sense involved with code re-usability:
1. Making sure we don't waste time in writing the same codee
2. Making sure that long applications are broken up into more readable applications
But I feel we've finally gone way over the edge, by these simple but needed changes in how we code, way too far into OO-land.
I feel there are times when OO can be useful, but not when you are coding coldfusion applications 99% of the time.
Coldfusion is a very powerful language for creating web applications, but is most know for it's speed of concept to results, Rapid Application Development. So that means there has to be a logical path from a to b, and that's the end of the application.
We are getting invested into things that may be interesting but are inhibiting our speed of delivery.
Simply said, Object Orientation, requires thinking in non-logical ways, that make it hard to work with and hard to communicate about.
What happened to plain old english logic?
I felt this when I had taken my first java class, I could figure out how eventually to do whatever i wanted, but no one would talk in a logical manner.
If I wanted to X, what things do I need to do X. A Simple Question, but because of object orientation, there was no way to logically describe the problem and solution.
Object Orientaton sounds really fascinating, but experiences like really a waste of time.
I have no problem finding new ways to both improve the quality of the code, and improve the speed of delivery, but I have never believed OO was the path to do that.
I am sure there can be a more logical approach to working with Java, without having to use OO language.
This goes along with CFC as well. Which were originally meant to be used for web services only, which is fine. But now everyone wants to use them for non-webservice related projects?
Doesn't anyone have a clue how to code for scalability? It's interesting and new ways of doing things, but they are not always the best ways.
We have to use our common sense.
So what things can we do to improve coding quality?
Start with the basics:
2. Code Readability including good indenting
3. Use a Project Management Process to avoid coding mistakes
5. Learning from Mistakes
My Motto - "Doing it the right way the first time"
Understand how to code for best performance, and code as if each application will be serving millions of users consistantly.
Understand how to write the best sql statements to get the data you want, but write it for performance. Use stored procedures, dts packages, all the functionality to move cf scheduled events into the database, so the web server can just focus on serving pages.
There are so many ways that we fail every day to just do the core, and all of us are into whatever the current fad is.
If there are other ways to be better coders, I am sure eager to know. I do not assume I know it all. But I do try to know what works, and what is a waste of time.
Coldfusion is about speedily creating great applicationss, so are you?