!kind of dormant, sitting on the shelf of ideas!
demo of how to schedule a unit of work (with unix sockets):
class Unit def run puts Process.pid end # # In case of error, this method will be invoked. The unit of work # is not put back on the queue (nevermind a lower priority queue) # but it's on my radar. Any exceptions raised in this method are # swallowed. # def recover(e) Bugsnag.notify(e) end end pool = XPool.unix 2 pool.schedule Unit pool.shutdown
demo of XPool::Process objects.
class Unit def run sleep 1 end end pool = XPool.unix 2 process = pool.schedule Unit p process.busy? pool.shutdown
$ gem install xpool