Re: [web2py] Re: Broken pipe with mysql

2017-06-29 Thread Richard Vézina
Hello Alexia, This is a pretty old thread : https://groups.google.com/d/msg/web2py/Iu36WNoWkX4/bgIob2R6UjsJ I suggest you to open another one... And tell us more on the issue you experiment, we don't have enough informaiton (traceback, setup, web2py version, os, etc) to help. Since 2011 web2py

[web2py] Re: Broken pipe with mysql

2017-06-24 Thread Alexia Death
This is still an issue. If for whaterver reason db backend closed the connection my shell running daemon script will be stuck in 100% cpu consuming exception loop and no way to make the model re-establish the db connection even if I do catch the exception. As an ugly workarund I could drop out

[web2py] Re: Broken pipe with mysql

2011-06-15 Thread Álvaro J . Iradier
I agree there's not way to notify web2py that the connection is lost, but isn't it possible to detect that the connection broke after the error is raised, and try to reconnect? Thanks. On 15 jun, 03:25, Massimo Di Pierro massimo.dipie...@gmail.com wrote: This presents logical problems. It just

[web2py] Re: Broken pipe with mysql

2011-06-15 Thread Massimo Di Pierro
Consider this code: 1) connect 2) start transaction 3) insert a record 4) select 5) insert another record 6) close transaction If the connection is lost between 4 and 5 and you reconnect what should the workflow be? Jump to 1? Jump to 6? Should 5 be executed if 3 was not committed? I do not

[web2py] Re: Broken pipe with mysql

2011-06-15 Thread Álvaro J . Iradier
I agree with Ron. If connection is broken between 4 and 5, I would expect the transaction to be rollback (it was not commited), and an error raised. Probably that request will fail, but at least the connection is not dropped and not recoverable. I guess in a server restart or shutdown, the server

[web2py] Re: Broken pipe with mysql

2011-06-15 Thread ron_m
Unless step 6 is reached and completed if the client closed then I would expect the database server to detect the closed connection and rollback on its own since there is no way to recover the state built on that connection or if the database server is restarted then the database server should

[web2py] Re: Broken pipe with mysql

2011-06-14 Thread Massimo Di Pierro
This presents logical problems. It just should not happen. Edit the mysql config file and change the timeout. If the database is restarted, web2py needs restarting because there is no mechanism in the database connection API to notify web2py (or python) that a connection lost. On Jun 14, 4:06