From: Joel VanderWerf Date: 2004-01-21T15:07:31+09:00 Subject: Re: drb server efficiency while running in irb Joel VanderWerf wrote: > > I've noticed that a drb server running in irb handles requests at a > different rate depending on whether the main irb thread is running > separately or has joined the drb thread. It's *much* slower as a > separate thread. Typically the difference is about 1000 req/sec vs. 3 > req./sec. That is puzzling to me because the irb thread isn't doing > anything but waiting for input. Both threads are priority 0, not that it > should matter. On further investigation, it seems the problem is drb in conjunction with readline (and there's nothing particular about irb causing the problem). Two other data points that may shed some light on the drb+readline problem: - Replacing drb with a generic threaded socket server restores normal throughput (still using readline). - Replacing readline with gets restores normal throughput (still using drb). Very strange. Maybe something in the readline lib is keeping drb from being responsive, but why doesn't that make the socket server unresponsive, as well? I'll spare y'all the code this time (but ask if you want it). Eventually maybe I'll figure it out...