Forums

Increasing uwsgi timeout

Hello,

I keep getting the following errors: 2017-01-26 20:01:34,890 :IOError: write error 2017-01-26 20:01:34,891 :Error running WSGI application 2017-01-26 20:01:34,891 :GeneratorExit

My app is processing intensive and can take a while to run (order of minutes). Is there a way to increase the uwsgi timeout?

Thanks!

The timeout is from our loadbalancer so it affects everyone and we're not going to raise it. It's already very high (at 5 mins). No user is going to sit and look at a web page while it spends 5 minutes loading. I would suggest doing any long computations in a scheduled task and periodically checking to see if it's done. Then you can show your users that something is actually happening in the background instead of a page just taking so long to load that they assume the site is broken and go away.