Hacker News new | ask | show | jobs
by nixxle 5301 days ago
How easy/hard/logical would it be to implement this for a medium-size website with about 250k monthly visits?
4 comments

I don't think it's logical. Stock PHP can easily handle a website with 250k monthly visits. Or, rather, your speedups will most likely come from talking to the database less, doing less IO, that sort of thing. CPU probably isn't your bottleneck now.
Fair enough answer. Thanks! I'll report back when we hit 800m. ^^
The ironic thing about Facebook releasing this is they're (and a handful of other sites) are the only ones that would really benefit from this. I do love that they release it as open source.

At my last company, we handled about 20 million API requests a day through a PHP API. Granted, the request and response were smaller than a standard webpage, but that was using stock PHP (hell it wasn't even custom compiled, it came straight from the Debian packages).

So, you need to hit a pretty huge amount of traffic before something like this makes sense. Of course, it's always neat technology to play with.

Not everybody using PHP is serving web pages. Zynga use PHP to do server side game simulation, I expect there are a myriad of smaller companies doing CPU intensive tasks in PHP that will welcome these developments.
Surely you used opcode caching?
Presumably he just installed the php-apc package
Even when you hit 800m, you'll be fine. Your performance gains will be outside of PHP via good cache usage, (opcode cacheing as well, but that should go without saying), avoiding hitting the disk or the DB, etc.
More details: That's about one hit every ten seconds. While I know that you'll get bursts, you still shouldn't be exceeding 10 hits per second very often. Any web framework can handle that; the reasons why you can't sustain that or can't get good performance out of that are going to be found in your code, not the framework code, and linear speedups probably won't be the difference between "working" and "not working".
Are you finding that your visits are starting to actually make a performance hit on the servers? For that kind of scale, assuming your code isn't doing weird things, the lowest tier Linode VPS or similar should be more than capable of serving the pages.
No, we are not experiencing any trouble at all. I'm just always looking for new ways to optimize and keep me and my colleagues busy. Playing with kind of stuff seems like fun.
Others answered the logical part of the question. I would be interested in how easy/hard it is. If anyone tried to get it running.