The hack that I used to get around this problem was to catch the exception and try the connection a second time in the first function used in each page (that loading the user in that case). This woke up the MySQL server and did the trick.
On 7 May 2012 19:46, Mike Orr <[email protected]> wrote: > > On one site I ended up polling the DB via a cron job. Nasty hack, but > > it got the job done when none of the other options described worked. > > I used to have a lightly-used site that would sometimes go several > days without a request, so I had cron restart the application every 8 > hours. > > -- > Mike Orr <[email protected]> > > -- > You received this message because you are subscribed to the Google Groups > "pylons-discuss" 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/pylons-discuss?hl=en. > > -- You received this message because you are subscribed to the Google Groups "pylons-discuss" 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/pylons-discuss?hl=en.
