From: Mike Sassak Date: 2009-08-18T02:45:28+09:00 Subject: Re: task/work queue --001636eedf968d001f047159f77e Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit On Mon, Aug 17, 2009 at 11:46 AM, Gurpal 2000 wrote: > Hi > > I have created essentially a webapp using sinatra/webrick which allows a > user to queue bits of work. These bits of work are essentially long > running processes. > > So i was thinking of using the Queue class to queue these requests and a > different thread to work thru the list (for example encoding videos). > > The user should be able to check on the progress of list AND > reorder/move items up/down the list. > > Now i've hand written stuff like this in java/servlet, but in Ruby > what's the best way to ensure that the queue can be enumerated in a > synchronized way? and in a Queue what's the best way to reorder items? > would i have to use an indexed/synchronized array or something? > > Any pointers helpful > > Thanks > -- > Posted via http://www.ruby-forum.com/. > > Check out this list of Queuing libraries for Ruby on Ruby Toolbox: http://ruby-toolbox.com/categories/queueing.html. You might not find anything that fits your requirements exactly, but you could definitely find some inspiration there. Mike --001636eedf968d001f047159f77e--