From: Robert Gleeson Date: 2009-11-19T10:45:24+09:00 Subject: Re: queuing work in a web app (sinatra/webrick) > Sure, i got this code from the Oreilly Ruby Cookbook. Is it bad code > then? The book seems to be a little outdated - for example, i rarely see people defining setters themselves nowadays, especially when you can use attr_writer :pause . I'm not sure why they didn't pick up on what could be an infinite loop, or at least a loop that can repeat itself many, many times. > Again this doesn't happen when i use similar code in Java... I don't know why that is in Java - in C, Ruby, an infinite loop is going to consume a lot of CPU power unless you take precautions. -- Posted via http://www.ruby-forum.com/.