View Single Post
Old 06-11-2004, 03:03 PM  
Nathan
Confirmed User
 
Industry Role:
Join Date: Jul 2003
Posts: 3,108
Quote:
Originally posted by aiken
Hey, Nathan -- I'm going to have to respectfully disagree with you here. Hopefully nobody who goes to all of the effort to write a C/C++ app is going to run it as an Apache CGI module. If you were determined to use Apache, a custom mod_ would probably make the most sense, but why even bother with that?

In my opinion, the highest performing web app is going to be a pure C application with built-in web serving. Of course, this is massive, insane overkill for almost any application, and it means that in addition to your actual app, you effectively have to maintain a web server as well (well, you can buy web server source code off the shelf, or a few other options, but it gets crazy).

All that said, I can't imagine a web app that anyone in this industry is going to need that PHP wouldn't be able to do just fine. The development costs and complexities with C/C++ are dramaticalyl higher, so if raw performance is an issue you'd probably be better off going PHP and just throwing more hardware at it than going C.

Cheers
-b
Yes, exactly! Look, I myself said that there are many ways to have "C" used for the web, and I only looked at the slowest possible, meaning as a CGI. Obviously anyone that REALLY needs performance, performance that PHP can not handle, would use either an apache module, or better like you said, a standalone server.

I totally agree with you there, but I did not talk about that. Why wouldn't I agree, I'd say I am the best example. You mentioned that you can not imagine a web app that anyone in this industry is going to need that PHP wouldn't be able to do just fine. I'll tell you one, counters. I mean public ones, not your own little counter for your webpage. In that kind of environment, a standalone web server is your best bet. Or else you will be a second web side story and need 50 servers to handle your traffic, or 10 like sextracker (I think its 10? not sure exactly, might be 5).

I have written statistics apps that at peak times handled over 80 million impressions a day on a single server without huge problems, and that while offering statistics others dreamed of. Thats over 1000 concurrent users at peak time btw AnalProbe

So yes, for HIGH-END performance HUNGRY systems, you will need to use C, obviously. Why would you not anyway.

But like I said before, 99% of the people here will NEVER have a system that needs more than PHP.
__________________
"Think about it a little more and you'll agree with me, because you're smart and I'm right."
- Charlie Munger
Nathan is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote