您可能应该看到
the Heroku devcenter article,因为这些信息会更有帮助,这里有一个小小的总结:
要回答超时问题:
Cedar supports long-polling and streaming responses. Your app has an initial 30 second window to respond with a single byte back to the client. After each byte sent (either recieved from the client or sent by your application) you reset a rolling 55 second window. If no data is sent during the 55 second window your connection will be terminated.
(也就是说,如果你有Cedar而不是Aspen或Bamboo,你可以每隔30秒左右发送一个字节来欺骗系统.它可能会起作用.)
要回答你的dynos问题:
Additional concurrency is of no help whatsoever if you are encountering request timeouts. You can crank your dynos to the maximum and you’ll still get a request timeout,since it is a single request that is failing to serve in the correct amount of time. Extra dynos increase your concurrency,not the speed of your requests.
(也就是说,不要费心添加更多的dynos.)
request timeouts:
检查代码是否存在无限循环,如果你正在做大事:
If so,you should move this heavy lifting into a background job which can run asynchronously from your web request. See 07002 for details.