On Aug 23, 2011, at 11:21 PM, limodou wrote:

> On Sat, Oct 23, 2010 at 9:22 PM, Michael Bayer <[email protected]> 
> wrote:
>> 
>> pool recycle means a connnection that is 3600 seconds old will be thrown 
>> away.   does not help with reconnects.
>> 
>> When a "server gone away" error is detected, the entire connection pool is 
>> thrown away and rebuilt.  So assuming one engine, you'd get this error once 
>> for each connection that is still checked out and attempts a new operation.  
>> Subsequent transactions will proceed since the pool has been rebuilt.
>> 
>> There was also a Mysql-reconnect bug fixed in 0.6.3 where previous versions 
>> might have impacted this.
>> 
> 
> I want to know if this means that the first transaction will still be
> failed, and others will be successful?

When the error is received, whatever transactional state has occurred on that 
connection is gone - however, if you're getting this error on the very first 
moment the connection is used, there's no state on the connection in any case.


> And sqlalchemy can automatically rebuild at the time the error occured
> but not the next time?

Not sure what the question is here.  You can call engine.dispose() at any time 
to rebuild the connection pool completely, if you were building an approach to 
"ping" the connection ahead of time perhaps.



> 
> -- 
> I like python!
> UliPad <<The Python Editor>>: http://code.google.com/p/ulipad/
> UliWeb <<simple web framework>>: http://code.google.com/p/uliweb/
> My Blog: http://hi.baidu.com/limodou
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "sqlalchemy" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/sqlalchemy?hl=en.
> 

-- 
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en.

Reply via email to