We’ll live blog this one again and capture my thoughts and notes from the post as it’s happening…
No reason to use anything but mongrel right now… the HTTP Server Library…
What’s the perfect stack? Let’s look at front ends…
Pen (errr)… Pound (laf, we used to use this)… HAProxy (ding ding ding)… Lightspeed (free version is crippled)… Apache/mod_proxy (does work but it’s loated)
Nginx: From Russia, with Love … bent on performance, super small, growing, event driven architecture, keep an eye on it…
The suggestion: Nginx + Mongrel + Monit
Caveats: Nginx buffers uploads… and there is no connection rate limiting…
Swiftiply : Teaching the Dog new tricks
- Event Driven Mongrel - removes ruby threads and socket handling from Mongrel Core
- Replaces with EventMachine event loop
- Mongrel becomes single threaded, event driven
- Stands up much better to high loads
- No context switching for threads… ends up allowing larger throughput…
Swiftiply Proxy - faster than HAProxy…what? are you serious? Registered mongrel workers that are event driven… talking to the proxy through a backend port of 8000… meaning self registration (automatic configuration) and scaling on the fly by booting more mongrels…
Virtualization seems to be a big thing around the conference today… funny as how that was the theme last year at TechEd… Breaking up services into virtual machines… modularize it…
Using GFS can help… Virtualized machines on SAN and booted from USB thumb drives… using GFS to deploy your app to one node and have all of your mongrel machines running off of the one file system…
Average mongrel size for a 64bit EngineYard is 70-120mb per …
Getting rid of :includes and RMagick is key to victory… (:include? really?)… add indexes and dont be afraid of custom SQL.
Don’t use FS for sessions… script/runner is massively inefficient… try not loading all of rails… use plain MySQL + Ruby instead.
Rails is 80/20 … you’re on your own for the 20%… learn how to write custom mongrel handlers for perf critical sections… Rails is the culprit, not Ruby for speed… Cache Cache Cache Cache…
Good session… learned quite a bit.
Was there any mention of the Varnish HTTP proxy? I love Nginx, but I think in the next year or so Varnish is going to be mentioned in the same breath as Nginx when talking about what to place in front of mongrel.
No mention of Varnish, in fact… before you said something about it, I’ve never heard of it… and I spent a few weeks researching for more HTTP proxies to replace my Pound install…
What are the advantages of Varnish?
I’ll have to give it a look…
Varnish:
http://varnish.projects.linpro.no/