From ec0621d81602ce7f7e24ce7e9194ba2022c2c44c Mon Sep 17 00:00:00 2001 From: Andre Arko Date: Wed, 6 Nov 2013 13:47:53 -0500 Subject: close persistent connections before forking --- lib/bundler/parallel_workers/unix_worker.rb | 6 ++++++ 1 file changed, 6 insertions(+) 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 -- cgit v1.2.1