Thursday, August 23, 2012

Choosing To Use PHP/Kohana

There seem to be so many blog posts about using Ruby on Rails or Python/Django these days that I thought I'd voice some thoughts about how PHP/Kohana is relevant and still a strong choice.

Let's get this straight though, the languages:
  • PHP
  • Ruby
  • Python
And the frameworks I'm talking about are:
  • Kohana (PHP)
  • Ruby on Rails (Ruby)
  • Django (Python)
It can be a tremendous ear sore when people mix these up.  On the other side of the spectrum, it's also annoying to hear people rant about which languages are better than another.  It's very important to understand that the 3 of these languages can accomplish the similar goals.

If you're not familiar with Kohana you can find it here.

Kohana is still a growing framework, but it's very strong and has a lot of potential.  There have been some ORMs such as Sprig and Jelly developed by some talented developers.  It has very fast benchmarks and good code organization through an HMVC structure.

All software is built for a purpose, the goal should always be reaching that purpose while maximizing the return and minimizing the energy expenditure.  And the value I'm talking about is not always quantifiable but there is tremendous value in building a team or growing a technology. 

The choice is clearest when cost is a very prohibitive factor.  PHP developers are in the greatest quantity out there and hosting costs for Apache-PHP-MySQL services are amongst the lowest.  In addition, while some give a notion that PHP is growing dated is still amongst the higher performers.

There is something to be said about appreciating a language because of its elegance.  When it comes down to keystrokes the fewer the better.  It's true that when we're talking about development the real work that gets accomplished is physical work.  But the greatest deal of work that gets done is the architectural work.  Designing well thought out software is 80% of the battle.  When we talk about debugging problems in software the more teammates getting involved later in the development process the most costly the issue becomes.  Practicing unit testing and regression testing properly goes a long way.  And when there is a launch making repairs post launch can require migration strategies and all kinds of headache.  While debugging in inevitable, a poorly thought out project can cost ten fold in comparison to a well built project.

I've heard that there are many unskilled PHP developers in the market.  I think it's appropriate to say that using Ruby or Python can also befall unskilled developers or even skilled developers who are poor decision makers (e.g. - tunnel or narrow visioned).  The important part of building a team and therefore executing a project when you're a team lead is to spend time with each of the resources you bring into the project.  Getting on the same page with all of your team members is always key.  As with PHP, there are skilled PHP developers who can build strong object oriented code.  Also, in the same vein, PHP is also closer to C/C++.  Most C/C++ developers tend to have stronger backgrounds.

Ruby has gained loads of ground from people hearing that it is able to build applications in months rather than years, but the real benefit is the best practices followed by its developers which can translate into other languages.

Don't get me wrong though.  Ruby and Python are great languages and I fully appreciate their respective frameworks when I work with them.  Python also has a large number of highly optimized routines.

No comments: