News for hackers. Stuff that matters.
Re:OKWS, the Ok Web Server (behind OK Cupid) by jrockway on Thursday January 06, 2011 @09:58PM (#2078372)
This is a good design. For a project I've been working on recently, I've organized it as a set of loosely-coupled async applications. That way, I can run them all in one process (with ZMQ inproc messaging), or run them all in separate processes (with TCP or Unix sockets), depending on my needs for reliability (more uptime because I can deploy-and-restart one tiny component at a time) or memory usage (all in one address space = more sharing). It's worked quite well; I love being able to stop one component, deploy a new version, and restart it without affecting the rest of the app or losing data. It makes "oh, this process seems to be behaving oddly right now" much easier to work with -- SIGTERM the faulty component, watch it return to normal, debug without stress, commit fix, run tests, deploy new version, SIGTERM again, problem fixed. Relaxation driven development, I'll call it.

But what I don't see is how this applies to OkCupid and web servers. To me, their website looks 99% static, with a web form that sends messages. The "secret sauce" is all offline background processes that builds recommendations, sends email, etc.; certainly nothing to do with HTTP. And once your website is nearly static, you stick a cache like Varnish in front of it, and you can serve pages as fast as your system bus can stream from memory to the network card. All without writing your own web server, and without using C++.

That said, it is the nicest C++ app I have ever used.

Re:OKWS, the Ok Web Server (behind OK Cupid) by there on Friday January 07, 2011 @12:39AM (#2078730)
To me, their website looks 99% static, with a web form that sends messages.

have you used okcupid?

Re:OKWS, the Ok Web Server (behind OK Cupid) by jrockway on Friday January 07, 2011 @12:44AM (#2078735)
Yes. It's pretty much the same every time I log in.