diff options
author | Andre Arko <andre@arko.net> | 2013-11-06 13:47:53 -0500 |
---|---|---|
committer | Terence Lee <hone02@gmail.com> | 2013-11-09 18:39:50 -0500 |
commit | 8a6c322735e5f7c3327960791a14bfec60971fde (patch) | |
tree | 408fb47ea9c2376802181aeb2106bdf5baffd933 | |
parent | 628927b6eebf2523ad18f7042da6ac598d000d61 (diff) | |
download | bundler-8a6c322735e5f7c3327960791a14bfec60971fde.tar.gz |
close persistent connections before forking
-rw-r--r-- | lib/bundler/parallel_workers/unix_worker.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/bundler/parallel_workers/unix_worker.rb b/lib/bundler/parallel_workers/unix_worker.rb index ce7b7fe9ed..51c2d0d89c 100644 --- a/lib/bundler/parallel_workers/unix_worker.rb +++ b/lib/bundler/parallel_workers/unix_worker.rb @@ -14,6 +14,12 @@ module Bundler end end + def initialize(size, job) + # Close the persistent connections for the main thread before forking + Net::HTTP::Persistent.new('bundler', :ENV).shutdown + super + end + private # Start forked workers for downloading gems. This version of worker |