Hacker News new | past | comments | ask | show | jobs | submit login

You can, but Node.js is often a better choice than PHP.

Caching: you can have ONE node.js process listening to all requests, and it can keep the cached info in memory, to be looked up much more quickly. In PHP, you'd have to load the entire script environment, connect to an external source like Memcached or APC, etc.

Waitlist: Similar to caching, except Node.js can hold off on responding to the request until the response came back. It's MUCH harder to make something like PHP iterate through the waitlist because a bunch of scripts might get called at once, and the way it works, all of them will have to sleep. With Node.js, only one process has to sleep -- or handles something else while you're waiting.

etc.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: