Class: Bundler::ParallelWorkers::UnixWorker
- Defined in:
- lib/bundler/parallel_workers/unix_worker.rb
Overview
UnixWorker is used only on platforms where fork is available. The way this code works is, it forks a preconfigured number of workers and then It starts preconfigured number of threads that write to the connected pipe.
Defined Under Namespace
Classes: JobHandler
Constant Summary
Constants inherited from Worker
Instance Method Summary collapse
-
#initialize(size, job) ⇒ UnixWorker
constructor
A new instance of UnixWorker.
Methods inherited from Worker
Constructor Details
#initialize(size, job) ⇒ UnixWorker
Returns a new instance of UnixWorker.
17 18 19 20 21 |
# File 'lib/bundler/parallel_workers/unix_worker.rb', line 17 def initialize(size, job) # Close the persistent connections for the main thread before forking Net::HTTP::Persistent.new('bundler', :ENV).shutdown super end |