Something like this is now in trunk. Just do

db = DAL(...)

please take a look.

On Apr 21, 1:12 am, Igor Gassko <gas...@gmail.com> wrote:
> Could you please post on this thread, once there's built-in solution
> for keeping pooled connections alive?
> For now, I've seen that you may end up with several dead connection in
> the pool, so slighly better solution might be as follows:
>
> for x in range(10):
>     try:
>         db = DAL(connection_string, pool_size=5)
>         break
>     except:
>         import time
>         time.sleep(1)
>
> On Mar 26, 6:04 pm, mdipierro <mdipie...@cs.depaul.edu> wrote:
>
>
>
> > Eventually a fix at the web2py level would not be much different than
> > this.
>
> > Massimo
>
> > On Mar 26, 10:03 am, David Zejda <d...@atlas.cz> wrote:
>
> > > Thanks. The workaround works, even when keeping the pool. :)
>
> > > D.
>
> > > > try:
> > > >     db=DAL("mysql://a:b...@localhost/c", pool_size=5)
> > > > except:
> > > >     db=DAL("mysql://a:b...@localhost/c", pool_size=5)
>
> --
> Subscription settings:http://groups.google.com/group/web2py/subscribe?hl=en

Reply via email to