So if you replicated their special and custom 'platform' in Ruby or Python and it exceeded PHP's performance by miles what would their reasoning for continuing to use PHP be?
This is a legitimate question due to speed comparisons I've seen between PHP and Python/Ruby.
Also, it seems like the obligatory "if you replicated their special and custom 'platform' in C and it exceeded Ruby or Python's performance by miles what would their reasoning for continuing to use Ruby or Python be?" People like the language, deal with it...
Because they're costs in replacing an entire infrastructure that go beyond simply making the choice to switch to something else.
- How knowledgeable your current employees are with it (and willingness to adapt and switch, as well as how long it will take to be as productive after the switch)
- Time taken redo all your servers to support it and pay someone to do it
- Subtle bugs that may appear related to the platform switch and not being as knowledgeable about it at first.
- As someone else mentioned, they may actually like PHP. That may seem hard to understand for some, but heck, there are even people like that like Java. We might not fall under either case, but for the same reasons people like other things that people may find inferior (certain car brands, TVs, PCs components, etc), people apply the same logic to programming languages.
And the costs are not just high because of the labour. There's also a high degree of risk. In practice we know less about the running code than we think we do. It usually contains enormous amounts of knowledge about edge cases that will, most likely, be missed on the rewrite and cause trouble.
>Because they're costs in replacing an entire infrastructure that go beyond simply making the choice to switch to something else.
I'm assuming that they don't have to worry about any of that and are given three platforms (PHP/Ruby/Python) that, for the sake of my argument, all do the same thing. Then we ask the question, which would they choose and why?
While it's a worthy question to ask, it's not applicable to them outside of theory, since they have been using PHP since they started some years ago. If you rephrase the question to a company just starting out, then it would be more fitting :)
If you look at the larger companies that do switch platforms, the ones that generally make the leap usually do so without replacing the entire stack (Java to jRuby or Java to Scala, etc). Not always the case (since the language can still be hurdle itself), but the cost to switch in those sort of cases is far lower than jumping off the jvm/clr/etc.
I'm sure if you asked Facebook now (and got an honest answer) that they would totally agree they would have picked another language and platform than PHP to build on given what they have had to go through since. However, PHP is what the developers knew starting out and sometimes it's better to go with what you know than learning something entirely new as building something from scratch is already a huge undertaking that can wear you down. Adding the burden of learning a new language/platform at the same time can lead to taking on too much and slow progress/motivation as well as lead to procrastination or distraction. It might lead to regrets later, but the greater regret is not building at all than choosing the right platform.
Hey, it works, you shipped a working product and that's all that really counts.
I wonder, if all the endless man (and woman) hours spent on this site, masturbating over whether people should use Go, or why Go is the new hotness, or why don't people grok Haskell, or the latest Rails security fails, if instead people actually, you know, built stuff, even with PHP, then the conversation could be a bit more stimulating.
While I sympathize with the situation MailChimp is in, I am getting tired of this anti-elitist attitude of PHPers. Of course, part of the reason why I feel that way is because I think PHP actually is crappy, but putting that aside doesn't change much.
There's this notion that programming languages are all really the same, and devs are just a bunch of prima donnas chasing the newest thing. It couldn't possibly be that we have used PHP before and have good reasons for not wanting to use it anymore. No, instead we must be a bunch of groupthinking prigs, scoffing at PHP because we're afraid to let our peers see us using such a shameful thing. You can tell they think that by the title of the post.
I guess what I'm wondering is, at what point will they consider using PHP to be too costly? If:
- they already have a limited talent pool due to location and the business they're in,
- PHP only serves to reduce that pool even further,
- presumably software development is important to the future of their business,
- and they're not changing markets or locations anytime soon,
when will it get too expensive to continue using it?
What rankles is the digging in of heels, the attitude of "oh, if only devs could see how clean and great our PHP code is!" They see a tons of developers not interested in using the tool they use, and decide that all those people are simply mistaken, and just need to be convinced otherwise. The problem couldn't be on the other side of the table, no sir.
I wouldn't want to go back to programming PHP due to its many issues[1]. I especially wouldn't want to work somewhere that spends development energy on BobX[2] to make PHP easier to work with. That means I have to use two technologies that won't give me any way to advance in the industry, and will most likely hinder me at this point.
People really need to stop posting that fractal article. Any PHP dev worth their salt would be able to tell you that guy clearly has no major experience with PHP (or any understanding of OOP for that matter).
Here's a few discussions on just how wrong [1] and clueless he really is [2].
I have no doubt you can do a lot of powerful things with PHP, provided you have the experience and put in the man power + time. But this does not justify the use of PHP now (for new projects), it just means that if you happen to be stuck on PHP because of legacy code, you could make it work.
But to be fair, wouldn't you also have to put in the manpower+time to get the experience to learn to do it in another language?
PHP is not all procedural spaghetti code, it does have modern frameworks, some of which are quite nice. And despite it's flaws (yep... someone posted Veekun's thing, everybody take a shot) there are reasons for choosing it, such as low overhead for deployment, and ubiquitous availability.
Low overhead for deployment and ubiquitous availability are definite advantages for the beginning of a project. Unfortunately, those two advantages disappear when your site becomes successful. For a large user base, there's more overhead involved in keeping a PHP webapp running smoothly, and by that time you won't need ubiquitous availability because you'll be, hopefully, running and configuring your own servers.
I can only assume you're right because I have no experience with having a site that's successful by anyone's standards (much less doing it in Python or Rails), but to me that still leaves a lot of room at the bottom of the pyramid for sites and apps that might not have any reason to expect such a large userbase.
What I'm confused by, is why is this even a conversation? PHP is possibly the most used language in the world. I'd presume that there's tons of highly qualified engineers to choose from, who are already bought in to the value of the language.
There is a lot of stroke inducing legacy PHP code out there in the wild. A lot of people have had a really bad experience working on projects that used PHP. The ease of entry allowed flocks of inexperienced software developers to grow PHP projects like mushrooms throughout the world.
I think it's largely bad rep due to the ease of misuse and dodgy frameworks.
20 comments
[ 4.7 ms ] story [ 59.8 ms ] threadAlso, it seems like the obligatory "if you replicated their special and custom 'platform' in C and it exceeded Ruby or Python's performance by miles what would their reasoning for continuing to use Ruby or Python be?" People like the language, deal with it...
- How knowledgeable your current employees are with it (and willingness to adapt and switch, as well as how long it will take to be as productive after the switch)
- Time taken redo all your servers to support it and pay someone to do it
- Subtle bugs that may appear related to the platform switch and not being as knowledgeable about it at first.
- As someone else mentioned, they may actually like PHP. That may seem hard to understand for some, but heck, there are even people like that like Java. We might not fall under either case, but for the same reasons people like other things that people may find inferior (certain car brands, TVs, PCs components, etc), people apply the same logic to programming languages.
Economists call this phenomenon "Path Dependency" and it's all around us.
http://en.wikipedia.org/wiki/Path_dependency
And the costs are not just high because of the labour. There's also a high degree of risk. In practice we know less about the running code than we think we do. It usually contains enormous amounts of knowledge about edge cases that will, most likely, be missed on the rewrite and cause trouble.
I'm assuming that they don't have to worry about any of that and are given three platforms (PHP/Ruby/Python) that, for the sake of my argument, all do the same thing. Then we ask the question, which would they choose and why?
If you look at the larger companies that do switch platforms, the ones that generally make the leap usually do so without replacing the entire stack (Java to jRuby or Java to Scala, etc). Not always the case (since the language can still be hurdle itself), but the cost to switch in those sort of cases is far lower than jumping off the jvm/clr/etc.
I'm sure if you asked Facebook now (and got an honest answer) that they would totally agree they would have picked another language and platform than PHP to build on given what they have had to go through since. However, PHP is what the developers knew starting out and sometimes it's better to go with what you know than learning something entirely new as building something from scratch is already a huge undertaking that can wear you down. Adding the burden of learning a new language/platform at the same time can lead to taking on too much and slow progress/motivation as well as lead to procrastination or distraction. It might lead to regrets later, but the greater regret is not building at all than choosing the right platform.
There's this notion that programming languages are all really the same, and devs are just a bunch of prima donnas chasing the newest thing. It couldn't possibly be that we have used PHP before and have good reasons for not wanting to use it anymore. No, instead we must be a bunch of groupthinking prigs, scoffing at PHP because we're afraid to let our peers see us using such a shameful thing. You can tell they think that by the title of the post.
I guess what I'm wondering is, at what point will they consider using PHP to be too costly? If:
- they already have a limited talent pool due to location and the business they're in,
- PHP only serves to reduce that pool even further,
- presumably software development is important to the future of their business,
- and they're not changing markets or locations anytime soon,
when will it get too expensive to continue using it?
What rankles is the digging in of heels, the attitude of "oh, if only devs could see how clean and great our PHP code is!" They see a tons of developers not interested in using the tool they use, and decide that all those people are simply mistaken, and just need to be convinced otherwise. The problem couldn't be on the other side of the table, no sir.
[1] http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-de... [2] http://thedailywtf.com/Articles/We-Use-BobX.aspx
Here's a few discussions on just how wrong [1] and clueless he really is [2].
[1] https://news.ycombinator.com/item?id=4177516 [2] http://forums.devshed.com/php-development-5/php-is-a-fractal...
PHP is not all procedural spaghetti code, it does have modern frameworks, some of which are quite nice. And despite it's flaws (yep... someone posted Veekun's thing, everybody take a shot) there are reasons for choosing it, such as low overhead for deployment, and ubiquitous availability.
Low overhead for deployment and ubiquitous availability are definite advantages for the beginning of a project. Unfortunately, those two advantages disappear when your site becomes successful. For a large user base, there's more overhead involved in keeping a PHP webapp running smoothly, and by that time you won't need ubiquitous availability because you'll be, hopefully, running and configuring your own servers.
I think it's largely bad rep due to the ease of misuse and dodgy frameworks.