Re:Node.js and the new web front-end
by k3n on Monday October 07, 2013 @04:06PM
(#6510840)
Not impossible, but not easy either considering PHP is single-threaded and synchronous.
[ Parent
| on HN ]
Re:Node.js and the new web front-end
by anonymoushn on Monday October 07, 2013 @05:00PM
(#6511218)
I've never heard of languages being synchronous or asynchronous before. It looks like PHP ships with asynchronous DB APIs.
Ok, poor example; just consider that it's single-threaded. Pretty much the only threading support is by way of a young PECL extension called pthreads[1], which is still experimental and dangerous. Otherwise, you can use the PCTL extension[2], if you don't mind compiling PHP yourself (and if you're not on Windows, where it's not supported).