Hmmm… well…. what to say, except “I was wrong”. At least from a certain view point
Having started some new projects from scratch I decided to give up and use one of the many available web frameworks (Perl/Catalyst MVC). And, well, it wasn’t as bad as I remember it being last time I did it. Although to be fair I did take over those projects part way through their development, and not have much time to learn the underlying frameworks before trying to complete the project on time and to spec. Anyway, that’s a poor excuse for not being objective enough in a previous post and declaring (rather dramatically) that all frameworks suck. It’s not true. Only some of them do (I’m looking at you Struts). Yeah, yeah, I’m biased against Java, so what?! I was forced into using it at work to support a project of a guy who left and did the worst job I’ve ever seen. Mostly by using EJBs to talk back to the same server to get data that could easily have been retrieved via sql. Anyway, I’m floating off topic again.
MVC frameworks (and frameworks in general) do help save development time. Now that I’ve finally got my head around Catalyst (to some degree) and CDBI (to a greater degree) than I previously had, I can easily see how this is going to save me a lot of time on future projects. Granted the initial install (either via CPAN or other means) can be time consuming, but it’s a worthy one.
I’ve also just come across a nice comparison of frameworks (although it is over 2 years old so bear that in mind). Having read through the article and studied the graphs and data, I suddenly though, “Oh my God! I should have put that time into brushing up on Python and Django”. But having read through the comments, I realised my initial reaction was (one again) over the top. One particular comment struck a chord. The results in the article only show the finaly speed, and only in a limited scope (FastCGI), and also for a limited page build. A static page served via the frameworks is going to be less demanding than a dynamic page. And some frameworks are just always going to be faster. But what matters most (to me) is how easy it is to build a new page, or new functionality, or access a new database, not how quick the end app runs (although that does matter of course), but at the end of the day, the system admins can always help by putting my app on a faster server, or load balancing it, or adding better cacheing. If I can push a new app out the door in 30 days instead of 60 days, just by using a framwork, then I’m going to damn well do it. Speed is relative and really depends on your viewpoint.
We all want our apps to be the fastest. But development time, and correspondingly maintenance time and effort matter to. And at the end of the day, I know Perl, I’ve been using it for 12 years. I don’t claim to know everything about it, and I know I have a long way to go to learn everything I need to about Catalyst. So it doesn’t matter to me if Catalyst is slower to run on some random test, while I do appreciate the guys efforts to test and document the framework results, what matters is that I can build something quickly and effortlessly. At the end of the day that’s what frameworks are for, making my life easier…