微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

ruby-on-rails – 如何在Heroku上更改默认请求时间?

我的应用程序是基于Rails构建的,我的生产服务器是在Heroku上.

我的应用程序主要用于文件上传文件处理,处理请求需要50秒以上.根据Heroku配置,我的请求没有及时响应,并且由于请求超时,它将我发送到应用程序错误页面.

如何在Heroku上更改请求超时配置?

请帮助我使应用程序正常工作.

解决方法

根据 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.

原文地址:https://www.jb51.cc/ruby/270504.html

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐