Swiftiply support for Thin
-
Kevin Williams
- State changed from new to open
- Milestone set to 0.7.0
-
Alex MacCaw
Looks like a I used an old Thin repos to make the patch - a lot of things have changed since then so I'll update the patch to the lastest repos revision.
-
Alex MacCaw
Ok, here's the updated patch. At the moment I can get Swiftiply to do about 1226 requests per second, while nginx is around 5780.
-
macournoyer
thx Kirk, I'll wait for your feedback before applying the patch
-
macournoyer
post_init if @swiftiplyshould be placed at the end of Connection#process not receive_data or else the request will be resetted at each packet received.
That might be the reason why it's slower then expected.
-
macournoyer
I did a quick benchmarks w/ a small rails app and perf seems very much the same:
nice -n20 ab -n5000 -c3 0.0.0.0:8080/simple
Swiftiply: 109.93 req/sec
Nginx w/ unix sockets: 108.13 req/sec
-
macournoyer
uh? I think lighthouse ate your comment or something kirk, you posted the ticket description.
-
Alex MacCaw
I found out the reason for that performance problem (and am almost too embarrassed to admit to it). I was fetching the default index.html page, rather than doing a proper rails action. Nginx was configured for caching, so it served up that static page, while swiftiply was not. With that rectified I now get an average of 85.31 req/s for nginx, compared to 87.15 for swiftiply - which is very good for a ruby balancer. It's amazing to think that we can now deploy Rails apps with just a Ruby stack (forget about the C for the moment ;)). All anyone needs to get running is a couple of gems. They can even do the monitoring in God.
-
macournoyer
applied w/ some modifications, now on git master
thx a lot for the contribution Alex!
-
macournoyer
- State changed from open to resolved
-
Matt Todd
/me applauds excitedly!
-
John
- Tag set to cluster
Kaikella kunnioituksella,Nettikasinot voivat olla sekä hyviä että huonoja lompakollesi. Jos katsot mr bet-kasinoa, huomaat, että se voi auttaa sinua lopettamaan vihaamasi työn, hän sanoi, De acordo com as estatísticas, este cassino on-line tem o RTP mais https://mrbet-casinoplay.com/fi/ alto
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.