title: Why aren't my ruby processes exiting on my FastCGI shared server when using send_file?
body: <p>After developing an awesome app on my local machine without any consideration of how it would perform on my host, I have run into a terrible issue. I am serving files (.pdf &amp; .zip) through rails <a href="http://api.rubyonrails.org/classes/ActionController/Streaming.html#M000421" rel="nofollow noreferrer">send_file</a> so that I can log statistics. The only problem is that when two (or more) files are downloaded simultaneously, a new ruby dispatch.fcgi process must be started to handle each one. I understand this could be avoided by using <a href="http://tn123.ath.cx/mod_xsendfile/" rel="nofollow noreferrer">mod_xsendfile</a>, but unfortunately my host doesn't support that apache mod. So here's the weird part. These processes are being created as expected, but for some reason they are never exiting. As a test, I downloaded about 10 files simultaneously from a couple different computers. There were about 10 processes created, but none ever exited. Even minutes after their invocation and even after the downloads had been long completed.</p>
  
  <p>Why aren't these exiting? What can I do to avoid this problem other than switch to a real host that provides support for mod_xsendfile?</p>