async stuff

18 views
Skip to first unread message

Brad Midgley

unread,
May 11, 2012, 2:01:28 PM5/11/12
to ur...@googlegroups.com
Hey

async operation looks pretty cool. I've been working with
rack-fiber_pool and the fiber-aware eventmachine libs. It is all going
well so far with sinatra+thin.

One really curious thing I've noticed... after installing
rack-fiber_pool, my server won't serve anything that takes longer than
30s to process. The client gets a blank response (fwiw, the server
keeps thinking about it). I can't see any timeout code in the rack
plugin and I'm not sure how to track down who-killed-the-process
mystery. Anyone notice any clues so far?

fwiw, I also tried sinatra-synchrony but it may just be a little too
soon. That thing patches every blocking call you can think of and
somehow broke dns lookups for me.

--
Brad Midgley

Roger Pack

unread,
Jun 13, 2012, 4:31:26 PM6/13/12
to ur...@googlegroups.com
> One really curious thing I've noticed... after installing
> rack-fiber_pool, my server won't serve anything that takes longer than
> 30s to process. The client gets a blank response (fwiw, the server
> keeps thinking about it). I can't see any timeout code in the rack
> plugin and I'm not sure how to track down who-killed-the-process
> mystery. Anyone notice any clues so far?

Maybe EM is timing out the socket or some such?

Jeremy Nicoll

unread,
Jun 13, 2012, 5:44:55 PM6/13/12
to ur...@googlegroups.com
Do you have another piece of server software in between thin/sinatra?


--
Utah Ruby Users Group
ur...@googlegroups.com
http://utruby.org
http://bit.ly/urug_lunches
http://groups.google.com/group/urug/
- All meeting times and places can be found here.

** Please prefix your subject with "[JOB]" if your message is about job opportunities.

Brad Midgley

unread,
Jun 13, 2012, 6:27:23 PM6/13/12
to ur...@googlegroups.com
hey folks

it is funny... thin was trying to cut off every request at 30s but we
were blocking the reactor thread from running. So it was actually
broken behavior before that was "fixed" when the reactor was allowed
to run and shut down old connections.

We cranked up the thin timeout (but strangely, it can't be turned up
too much or thin just crashes)

Brad
Reply all
Reply to author
Forward
0 new messages