Eric,
I’m a bit surprised unicorn runs at all
let alone being faster than
Puma/Thin in some cases.
Well at least now there are public benchmarks to prove that unicorn
runs.
How many CPU cores is that? Is HT enabled? Which OS?
It’s 2 core and I think HT enabled. It’s OS X 10.9.4
I have no idea if unicorn even runs on OSX (or any proprietary OSes).
I doubt yahns does, but yahns supports kqueue on FreeBSD since March
2014 or so.
I haven’t tried yahns, but I’ll give it a shot and see if it works or
not.
There’s not much difference between server and laptop hardware nowadays.
That’s a good point, I just didn’t want people looking at the raw
numbers
and saying, “Hey, my server is way faster than that. This benchmark is
wrong!” Which seems common in most benchmarks. So, I added lots of
disclaimers.
I only develop on GNU/Linux, and occasionally port to FreeBSD as those
are the platforms where deployment usually happens. Multi-threading
performance might be better on Linux or FreeBSD for Rubinius, too.
Yeah, I will probably run a future test suite against Linux so that it’s
closer to a real server setup.
Agreed. I mainly develop and test using Rack.
Why don’t more programmers write against Rack directly?
Memory usage comparisons would also be a good bench, since that’s often
a limiting factor for VPS deployments.
unicorn w/4 processes combined = XXX MB
jruby server(s) w/4 threads = YYY MB
That’s a good point and I think I’ll add that dimension to a future
benchmark.
I do not believe that sentence 
Me either, I fixed it. Thanks for finding that.
Thin and Puma also support multi-process, too. So I think they should
be competitive in that config with unicorn on C Ruby.
For JRuby and Rubinius benchmarks, you should specify how many threads
those servers are running (and how many CPUs you have).
That’s a very sensible idea. It gets tricky balancing CPU and Memory to
have truly comparable benchmarks. I’ll have to see how best to fairly
compare the different servers.
Correct. Top performance was never the primary goal of unicorn[2].
unicorn is meant to tolerate imperfect (buggy!) applications and give
acceptable, predictable performance using multiple processes to
workaround limitations in C Ruby, frameworks and developer ability.
Yes, and I totally understand that, but I don’t think a lot of people do
the research to understand why Unicorn is different and where the
performance it does have comes from.
In contrast, yahns is completely intolerant of fatal application bugs.
It uses multiple processes on C Ruby, but also uses multiple threads,
and one-shot kqueue/epoll so it should work well with Rubinius.
yahns should be as fast as C Ruby or Rubinius allows.
Well now I have to try yahns!
I’ve long acknowledged unicorn and yahns are limited by Ruby performance.
So I’ve mainly focused on improving C Ruby performance in the mean time
(and also teaching myself lock-free programming in C).
It’s great that you are working on improving C Ruby performance. I don’t
have the C chops to contribute. Perhaps someday…
No surprise with a single worker and non-concurrent, stop-the-world GC.
Again, you’d be surprised how few people know about this stuff. Well,
maybe
you wouldn’t be surprised, but a lot of people read blogs and pick
whatever
the flavor of the week is. After the RapGenius blog fight with Heroku,
I’m
sure interest in Unicorn jumped a bit. I’m not sure a lot of people
understand when and why you would use Unicorn vs. a different server.
I suspect this is because of the lack of persistent connections support
unicorn. For real-world use, unicorn is designed to be useless without
nginx (or similar) in front of it.
That seems like a reasonable tradeoff to me.
Rainbows! requires a lot of reading and configuration, so I don’t blame
you. There’s too many options, really, and part of the reason I made
yahns[1] into a separate project.
Well that explains the difficulty I had then. 
Thank you again for posting here on a non-commercial,
mouseless-user-friendly list so I can respond 
You are welcome. I’m just glad to be able to contribute something useful
to
the Ruby community at large.
Note: I never post benchmarks for my own servers:
a) They’ll inevitably come off as biased
b) I don’t want to make other servers look bad
(but I am always allowed to make my own servers look bad)
Thus independent evaluations are very welcome 
That is a sensible stance to have. All benchmarks are biased, if only by
our lack of knowledge of what we are benchmarking. Some projects go too
far
to show that you should use them because of their awesome benchmarks.
Benchmarks are an important dimension, but they aren’t the only
dimension.
[1] http://yahns.yhbt.net/README
a webserver by a guy who can’t even do HTML :P)
I bet your web servers would be faster if you COULD do HTML 
(Also, nobody can really do HTML)
Eric, I’d also just like to say thank you for all the effort you put in
unicorn, rainbows, and yahns. They are excellent projects and we use
unicorn in production at work every day. At my previous job we used
unicorn
to power a site that raised millions of dollars to cure children’s
cancer,
so your work is doing a lot to help make the world a better place.
-Brian