worker_bee
Encapsulates a simple pipeline of threaded workers.
WorkerBee encapsulates a simple pipeline of threaded workers.
- Simple API to wrap up the usual Thread/Queue patterns.
1 2 3 4 5 6 7 8 9 |
bee = WorkerBee.new bee.input enum_of_work_to_do bee.work(20) { |work| ... stuff with input ... } bee.work(5) { |work| ... stuff with results of previous ... } # ... etc ... bee.results # the final set of results |
Get The Code
If you just want to use worker_bee, you can install it via RubyGems:gem install worker_bee
If you want to hack on worker_bee, clone it from GitHub:
git clone git://github.com/seattlerb/worker_bee