Gunicorn超时错误,我无法增加它
我在 Digital Ocean 上部署了一个 Flask 应用程序,当我执行大型请求时,日志错误是:
[1] [CRITICAL] WORKER TIMEOUT (pid:48)
我尝试增加 Gunicorn 上的超时这样,但错误仍然存在:
#gunicorn_config.py
bind = "0.0.0.0:5000"
workers = 2
timeout = 600
#Procfile
web: Gunicorn app:app --timeout 600
#env/Lib/site-packages/gunicorn/coonfig.py
class Timeout(Setting):
name = "timeout"
section = "Worker Processes"
cli = ["-t", "--timeout"]
meta = "INT"
validator = validate_pos_int
type = int
default = 600
desc = """\
知道我做错了什么吗?谢谢!
I have a flask app deployed on Digital Ocean,and the log error when i do a large request is:
[1] [CRITICAL] WORKER TIMEOUT (pid:48)
I tried to increment the timeout on Gunicorn this ways but the error persists:
#gunicorn_config.py
bind = "0.0.0.0:5000"
workers = 2
timeout = 600
#Procfile
web: gunicorn app:app --timeout 600
#env/Lib/site-packages/gunicorn/coonfig.py
class Timeout(Setting):
name = "timeout"
section = "Worker Processes"
cli = ["-t", "--timeout"]
meta = "INT"
validator = validate_pos_int
type = int
default = 600
desc = """\
Any idea what im doing wrong? Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
尝试指向您的配置文件
,请注意,要使此语句起作用,您还需要 wsgi.py 位于同一目录中,并具有以下
内容 干杯!
try to point to your configuration file
note that for this statement to work you need wsgi.py also in the same directory having the following
Cheers!