Method: PMap::ThreadPool#shutdown
- Defined in:
- lib/pmap/thread_pool.rb
#shutdown ⇒ Object
Public: Shuts down the thread pool and waits for any running threads to
complete
43 44 45 46 47 48 |
# File 'lib/pmap/thread_pool.rb', line 43 def shutdown @workers.size.times do @jobs << :stop_working end @workers.each(&:join) end |