From: James Edward Gray II Date: 2004-10-04T05:37:20+09:00 Subject: Thinking about Threaded IO I've not used Ruby's threads before, so I have what will probably be some basic questions. I'm pretty familiar with using native thread systems, but these "in processor" threads raise some questions for me. I'm especially wondering about IO. I've read that Ruby's threads can be dangerous when making possibly lengthy calls to the operating system. How does that affect threaded servers in Ruby? If you call gets() on a socket, does the program hang until that socket produces input containing a \n character? If so, what's the best solution? Use non-blocking IO techniques? I guess that's a pretty specific example and I am interested in the affects of this type of threading on networking code, but let me ask something more general. When should I be stopping to worry if this action I'm threading will stall the whole program? Where is this generally a problem? Thanks. James Edward Gray II