3 ms·
This is definitely interesting, but what I'm missing is comparison with a single dyno running Thin.
by arikfr 15y ago
This is definitely interesting, but what I'm missing is comparison with a single dyno running Thin.
- meskyanichi 15y ago1 Unicorn worker is roughly equivalent to a Thin instance. You can only put a single Thin instance on a dyno, meaning that the first benchmark is what you previously could only attain in terms of throughput. I might've not explicitly said this in my article, but see the first benchmark where I say: "1 Unicorn Worker (Roughly equivalent to a single Thin instance)" - stating that this is Thin's (and was Heroku's) previous limit. With Unicorn you can gain 3 to 4 times more throughput.
- arikfr 15y agoThanks for clarifying. The reason I asked, is that I thought maybe Heroku did some optimizations on their stack that uses Thin.
- meskyanichi 15y agoNo problem. I doubt there is anything app-server specific to the Celadon Cedar stack. Maybe the Bambidious Bamboo stacks there is Thin-specific configuration. But Cedar is meant to run anything you want through the Procfile, you could also use Mongrel or Rainbows or maybe even Passenger. But Unicorn gets my preference as of late! Amazing app server.
- joevandyk 15y agoUnicorn (3 workers) + Sinatra gets 2,300 requests per second. Thin + Sinatra gets 1,000 requests per second. https://github.com/joevandyk/unicorn-on-heroku https://github.com/joevandyk/unicorn-on-heroku for unicorn code/results. https://github.com/joevandyk/unicorn-on-heroku/tree/thin https://github.com/joevandyk/unicorn-on-heroku/tree/thin for thin code/results. The weird thing is I tried scaling up to 10 dynos (even tried 50). I didn't see any throughput improvement.
- meskyanichi 15y agoThanks for testing it out! Great results!
- joevandyk 15y agoIf your app is doing any network IO, I'd expect unicorn + multiple worker processes to give even better results over thin.
- arikfr 15y agoThanks for testing and for sharing the results.
- stephth 15y agoJust curious, where did you execute ab from? I've uploaded your code and ran ab from my laptop - I've tried it under 3 different internet connections - and I only get about 100 req/s.