Hacker News new | ask | show | jobs
by cheald 4821 days ago
For something like the query tests where you're IO-bound, Puma is going to annihilate the competition. For CPU-bound tests like JSON generation, unicorn with multiple workers is going to perform better.

It's worth noting that Rails' default JSON solution is the compatible-everywhere pure-Ruby JSON generator. Using a drop-in replacement like the oj gem will drastically improve throughput there.

I didn't get to the pull request for this round, but tweaking the GC parameters for the Ruby install should dramatically improve the general performance of the non-JRuby Ruby tests, as well. I'll see if I can get a PR in. :)

1 comments

Well yes please do this, not sure if it is allowed though since Oj gem is written in C ( I think )
So is the mysql2 driver (at least the slow parts), and Passenger is C++. C extensions are a common part of your standard Ruby deployment stack.