Ebb: C-Powered Web Server That Uses Rack – Faster than Mongrel *and* Thin
By Peter Cooper / March 4, 2008
Ebb is a small, extremely high performance Web / HTTP server designed specifically for hosting applications built upon Web frameworks such as Rails and Merb (and, in future, apps on other non-Ruby frameworks.) The design is event based (similar to that used by Ruby daemons that use EventMachine) but Ebb itself is written in C and dispatches requests to Rack adapters. This is a real leapfrog over the popular Mongrel and Thin daemons which are primarily written in Ruby, and results in scary levels of performance.
Since the start of 2008, it seems as if the Ruby and Rails deployment sectors have been on fire! Thin, a Ruby HTTP daemon that's faster than Mongrel, made it on the scene in January, then we discussed the problems involved in deploying apps here on Ruby Inside, and my own SwitchPipe arrived in February. Other systems such as Swiftiply have also continued to innovate. These are exciting times!
Comments
-
labria says:
March 4, 2008 at 1:38 pmEbb may be damn fast, but it's memory footprint is scary.
-
ste says:
March 4, 2008 at 2:05 pmRight after launching my application, the VSIZE skyrockets to 255M! (it's around 47M with Mongrel, and slightly less with Thin). Even the RSIZE is higher (35M vs. 32-33M).
The performance (reqs/sec) seems to be somewhat better, though. -
Peter Cooper says:
March 4, 2008 at 2:08 pmThis strikes me as likely to be a bug, since I'd expect it to have a lower footprint due to the way it's constructed. There must be a rather nasty leak somewhere (or a development environment type setting / debugging information, etc.) Perhaps the attention Ebb gets today will encourage some fixes.
-
Zdzichu says:
March 4, 2008 at 2:19 pmWhat about -d (daemonize) option? Doesn't work for me (ebb doesn't answer at all).
-
Forth says:
March 4, 2008 at 2:21 pmwhat's interresting with Ebb is that it performs better when backend takes time to answer ( few seconds) than other evented servers (afaik) : http://four.livejournal.com/841030.html
-
Robert Dempsey says:
March 4, 2008 at 2:53 pmIt is good to see more web server choices come out. As in free markets, competition is good, and in this case, we developers can benefit from better application performance. I hope the bar continues to be raised.
-
Arie says:
March 4, 2008 at 3:27 pmThe high VSIZE is a bug in the 0.0.3 release. Daemonize works for me, but the ebb_rails command seems to ignore the 'env' setting, and always defaults to development.
I manually editted the rails rack adapter to force it to production to run some tests. I didn't get anywhere the speedboost shown in the graph for real applications, more like 10% -
ry says:
March 4, 2008 at 3:38 pmForth, the concurrency code that you speak of has been reverted for the time being. creating the extra threads was quite costly. I would like handle this problem in the future, but for the time being this is not a feature of ebb.
Labria, the large memory usage is from overzealous buffering on my part. this can be fixed by modifying the a few constants in the ebb.h header file and recompiling (as described here). I don't think it is from a memory leak.
-
Arie says:
March 4, 2008 at 3:39 pm*rails applications, not 'real applications'.
It's not surprising the speedboost isn't that great for a rails application, considering the weight of a rails application.
-
Dan says:
March 4, 2008 at 4:44 pm@ry: have you tried running Valgrind with Ebb?
The traditional setup with Rails apps is to have something like Mongrel behind a web server like Nginx or Apache. Is Ebb designed to run behind a server, or is it meant to run stand-alone? If stand-alone, then I'm curious to see how its static file serving performance compares to Nginx.
-
Dan says:
March 4, 2008 at 4:55 pmI guess I should RTFM next time :). Ebb is meant to be used behind a front-end server.
Nginx would be the obvious choice for a front-end, but I've found that the Varnish Accelerator ( http://varnish.projects.linpro.no/ ) has even better performance when you take care of configuring your cache-related headers: Vary, Expires, Cache-Control, ETag and Last-Modified.
-
Felipe Giotto says:
March 4, 2008 at 5:30 pmIt's good to have more web servers! But, as many users are saying, how "heavy" is ebb to a web server? What if I have 5+ applications running at the same time? I think I'd better analyse them for a little more time... Anyway, this is good news!!
Best regards,
Felipe Giotto.
-
Peter Cooper says:
March 4, 2008 at 5:43 pmIt sounds like Ebb is, most likely, the "future" of this sort of stuff, but it's at least slightly amusing to me that SwitchPipe seems to be a lot easier and less burdensome at the present time. Of course, there ain't no 5000 requests per second, I'll assure you ;-)
-
Hawkerb says:
March 5, 2008 at 7:49 amwhy perofrmance / memory size is not compared to fcgid ?
Other Posts to Enjoy
-
Ruby’s Unary Operators and How to Redefine Their Functionality
Ruby’s Unary Operators and How to Redefine Their Functionality
-
The Split is Not Enough: Unicode Whitespace Shenigans for Rubyists
The Split is Not Enough: Unicode Whitespace Shenigans for Rubyists
-
The Mega Ruby News and Release Roundup for February 2012
The Mega Ruby News and Release Roundup for February 2012
-
A Lagom Review of O’Reilly’s ‘Sinatra Up and Running’
A Lagom Review of O’Reilly’s ‘Sinatra Up and Running’