I’ve been meaning to write this post for some time, but my relocation, client work and now sweltering heat has kept me busy. As I begin to prepare my presentations for next week’s YAPC::NA conference I feel compelled to finally throw down the gauntlet and write because I believe they are important points that seemed to be missed by most of the Perl community.
I’ve been following Andy Lester’s Perl Buzz blog since it launch and applaud his efforts to bring “fresh blood” to the Perl community. Like Lester I believe the Perl community has a lot to offer and by no means is a dying or irrelevant language. What I believe it does suffer from is what I will call a marketing problem. Some of it is “visibility” as Lester refers to it, but more of it is packaging, perception and presentation.
This thought has stuck with me for years, but it wasn’t until I read Lester’s Perl must decentralize, diversify and colonize post that I that I felt it was time to write about it here.
If you haven’t read the post I’m referring to or follow Perl Buzz I suggest you do.
So let me state upfront again that, for the most part, I agree with most of what Lester wrote.
I said for the most part though. Where I differ is in why other languages, PHP and Ruby (with Rails), are more en vogue. To me these are important points that are getting missed and overlooked by the Perl community that has lead to this condition.
These points are most apparent by comments made in the lead up to his three objects — decentralize, diversify, and colonize.
I’m certain that PHP has become a de facto choice for basic web apps because it’s just How You Do It these days. You see enough PHP in the context of the web, it starts to sink in.
This is generally true, but this view overlooks how PHP came to such a place of prominence in the web applications ecosystem. I don’t think PHP is a better then Perl in any means, in fact I thinks it’s pretty crappy stuff that I’ve never liked working with. Still PHP succeeded because it was just good enough and made running web application easier then anything else for most people.
PHP was free unlike Application Server Pages (ASP) or ColdFusion and was easier for hosting providers to offer and maintain then alternatives such as mod_perl or the resurgent FastCGI. It’s popularity was further enhanced as a default module of Apache making it’s availability through cheap shared hosting nearly ubiquitous.
Of course Perl and CGI for that matter is equally as ubiquitous, but they were and still are perceived as a less attractive option to many because it is harder to get something up and running. FTP a text file with a mix of HTML and PHP script and a .php extension and presto! it runs. Unless severely abused, PHP is more responsive because its engine is typically persistent thereby avoiding the performance tax any language running through CGI must pay. PHP does require a server restart like FastCGI or mod_perl to pickup changes either. Further, numerous vital (and then some) libraries come built-in and are then easily accessed where others languages like Perl leave that to the user assuming they have the rights to do so. The hosting provider could, and indeed some good ones will install a lot more then just the core distribution, but knowledgeable Perl hosts seem to be few and far between these days.
As an active member of the Movable Type community I’ve seen the difficulties Perl/CGI issues have caused users and impacted interest in Perl with a broader less adept user base.
Why is Ruby on Rails so popular? Is it better than Perl on Catalyst? Or is it just that people hear about Rails more? I suspect the latter, because perception is reality. When people perceive Perl as being dead, or not as powerful as other tools, it might as well be.
I whole-heartedly agree with Lester’s observation that perception is reality. Like his observation about PHP I think it misses an important point though.
Rails, in which Ruby would still be nowhere, made it easier for more professional developers to write applications with great user experiences quickly and easily. The genius of Rails is in its marketing.
I remember when I first heard David Heinemeier Hansson present on Rails how intrigued and even excited I was with how productive a developer could be. What really made Rails work so well in this context was that it was “opinionated software” that said “flexibility is overrated.”
This is of course heresy to the Perl community, but I think that perhaps the Perl community’s treasured there-is-more-than-one-way-to-do-it ethos needs to be broadened to include that sometimes one (highly preferred) way of doing things as an acceptable option.
This is why I was disappointed when I read about Catalyst. This is not to say that I think Catalyst is bad or not capable. It’s that it missed the most important advantage of Rails and why it was so successful in attracting a large fanatical community of developers so quickly. Catalyst wasn’t what I wanted.
I think there is a large group of users that don’t care about choice, but getting their job done as quickly and easily as possible. Business managers, entrepreneurs, investors, and the technologists working for them don’t care if a web application is written in Ruby or Perl or PHP or Java. What they do care about is providing a great user experience that will attract and delight users, grow a company, and provide the best return on their investment in time and effort.
Rails made that possible by having an opinion on its conventions (over configuration), JavaScript/AJAX libraries and so on that allowed it to create tool and libraries which helped developers write less software.
This is why so many of the most popular sites and web applications to launch are written using Rails, not just because people hear about it more.
PHP and Ruby on Rails lowered the barriers to entry and have reaped the benefits. Capable and powerful as it is, Perl has not.
I’m not sure precisely what moves the Perl community has to make, but I’m certain that without more (a lot more) attention to perception and marketing of Perl interest will wane. No amount of language theory or lightning talks or state of the onion will stop that.
I do hope that the Perl community does decentralize, diversify and colonize and that a big part of that work includes making it easier for developers to use and deploy Perl applications.