The strange thing is that all requests are affected *after* the db restart.

1) I thought that django opened a new DB connection on each request, if so
then it doesnt make sense that *all* requests after the DB restart raised
an exception

2) Is it possible for uwsgi to restart a worker that comes at an exception?


uwsgi cmdline: uwsgi -s 127.0.0.1:9001 -M 4 -t30 --post-buffering 1 -A 4 -p
6 -d /var/log/uwsgi.log --pidfile /var/run/uwsgi.pid --no-site --vhost


Versions:
uWSGI 0.9.9.2
django 1.3.1
postgresql  9.1



Thanks.

David




2011/11/4 Łukasz Wróblewski <[email protected]>

> ----- Oryginalna wiadomość -----
> > Od: "Roberto De Ioris" <[email protected]>
> > Do: "uWSGI developers and users list" <[email protected]>
> > Wysłane: piątek, 4 listopad 2011 7:09:18
> > Temat: Re: [uWSGI] After a DB restart, psycopg2 errors. Required uwsgi
> restart, Graceful recovery possible?
> >
> > Hi,
> > it looks like django never calls the reconnection. Is this an old
> > (<1.2)
> > Django version ? Which uWSGI version and options ?
> >
> > Is this 100% reproducible when you restart the server ?
> >
>
>
>
> http://stackoverflow.com/questions/4447497/django-how-to-reconnect-after-databaseerror-query-timeout
>
>
> http://stackoverflow.com/questions/1125504/django-persistent-database-connection
>
>
> --
> Łukasz Wróblewski
> http://www.nri.pl/ - Nowoczesne Rozwiązania Internetowe
> http://www.hostowisko.pl/ - Profesjonalny i tani hosting
> http://www.katalog-polskich-firm.pl/ - Najlepszy darmowy katalog firm
> _______________________________________________
> uWSGI mailing list
> [email protected]
> http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
>
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to