Search code examples
ruby-on-railsruby-on-rails-3heroku

How to change default request time out on Heroku?


My app is built on Rails and my production server is on Heroku.

My application is mostly used for file upload and file processing and it takes more than 50 seconds for the request to process. As per the Heroku configuration my request does not respond in time and it sends me to the application error page due to request timeout.

How can I change the request timeout configuration on Heroku?

Please help me out to make application working.


Solution

  • This is not possible according to Heroku's documentation

    The timeout value is not configurable. If your server requires longer than 30 seconds to complete a given request, we recommend moving that work to a background task or worker to periodically ping your server to see if the processing request has been finished. This pattern frees your web processes up to do more work, and decreases overall application response times.