From: 7stud -- Date: 2009-03-20T09:15:28+09:00 Subject: Re: Timeouts with Thread#join and Net:HTTP Rushi wrote: > # Join all the threads we have created > @threads.each{ |thr| > thr.join # Timeout:ERror thrown here after approx 1.5 mins > } > > > Wrapping my thread.join call around Timeout::timeout (http://www.ruby- > doc.org/stdlib/libdoc/timeout/rdoc/classes/Timeout.html) didn't help > either. > > Any suggestions how to make it *not* timeout so that I can finish > making all the API calls? I've tried hard but haven't been able to > find a solution I don't see how join can timeout at all the way you've called it. join should never timeout, unless you specify a limit: ------------------------------------------------------------ Thread#join thr.join => thr thr.join(limit) => thr ------------------------------------------------------------------------ The calling thread will suspend execution and run _thr_. Does not return until _thr_ exits or until _limit_ seconds have passed. If the time limit expires, +nil+ will be returned, otherwise _thr_ is returned. -- Posted via http://www.ruby-forum.com/.