asyncmy
asyncmy copied to clipboard
Lost connection to MySQL server despite periodic pings
Every 60 seconds I acquire from my pool and ping yet I'm still getting lost connections. Is ping working or is this not the way to prevent this problem? Am I not walking through all connections in the pool?
(2013, 'Lost connection to MySQL server during query')
await asyncio.sleep(60)
async with ws.pool.mysql_pool.acquire() as conn:
await conn.ping(True)
What about try pool_recycle?