> PHP might be still having the “king of web” status, but with node.js in the town, I don’t see that status staying for very long!<p>I doubt that. PHP will stay because of Path dependency, most webhosters provide PHP, because software is written in PHP. Software is written in PHP, because it is most widely supported. I like node better, though.
<i>The truth is out. node.js was faster than PHP by more 14 times! These results are astonishing. It simply means that node.js IS going to be THE de-facto standard for writing performance driven apps in the upcoming future, there is no doubt about it!</i><p>While I enjoyed the benchmark test, I believe the conclusion that this is going to be de-facto as a result of it's high performance is a bit premature. There are so many factors (both right and wrong) that contribute to the widespread adoption to a language/framework/technology, performance often being less important than you'd at first think.<p>EDIT: I'm not suggestion node will or will not be a de-facto. I'm suggesting that the factors contributing to a languages widespread adoption are varied and complex.
It's not really a node vs php comparison, it's a node vs apache/php/unknown config comparison. HHVM can be 40-80 times faster than php for some benchmarks. Maybe try that?
Some time ago at school the teacher asked to make a crawler so, as always I do it in node.js and mongodb.
The site to crawl has around 80K pages and 300 records on each page.
My script crawled and saved all that data (80K * 300) in less than 1 hour with around 100 concurrent requests.
The other students that wrote in ruby, python and php took days to do the same thing. Also they had to do by parts because if they requested all by once their pc would crash because of memory.<p>Also I didn’t need any test because since the first time I ran node.js it was instant fast, not like php, ruby or python.
If you're really worried about performance just look at chicago boss or raw Yaws with Erlang and or Elixir.<p>The real question for most projects should be which is faster to develop with and has a better ecosystem.
Wow, is this a parody? The lack of rockstar ninja references is confusing me.<p>"Hey guys, I was wondering if node really is faster than PHP, so I checked. It is! End of story."
As long as there is software built in PHP which are used by huge numbers of people (Wordpress, Drupal, etc) then it will continue to be important to huge numbers of people.<p>For many of the people using these tools, the benchmarks don't matter. Most people do okay with their Wordpress or Drupal sites. Application developers understand that the limitations of attempting to use a CMS as a platform and they have wide choices (not just PHP or Node.)
Just for fun, here's an unoptimized and un-async'd haskell version I threw together:<p><a href="http://lpaste.net/105557" rel="nofollow">http://lpaste.net/105557</a><p>It takes about a second. I expected it to be faster than node and php, but it being this much faster makes me think I got something wrong. The files generated aren't all the same.
The really approximated excluding concrete version information and using only read and write to disk commands statistics*<p>Personally i prefer <a href="http://www.techempower.com/benchmarks/" rel="nofollow">http://www.techempower.com/benchmarks/</a> reply if anyone knows something better than that one
I'd like to see the author make an attempt with the React library [1] in PHP as well. You don't have to abandon your language of choice to gain the ability to do asynchronous I/O.<p>[1] <a href="http://reactphp.org/" rel="nofollow">http://reactphp.org/</a>