Hello Everyone, Need some suggestion/insight on some use case we have:
We have python django web application which uses sqlalchemy v1.3.13 (mysqldb) to communicate with AWS Aurora (RDS). This application uses AWS Secrets Manager for managing database credentials and utilizing sqlalchemy (w/ mysqldb & queuepool) to read user/password during application start-up via settings.py/manage.py. For security reasons, we have to rotate database credentials frequently and for that we are using AWS Lambda to update in the Aurora DB & secrets manager. We are using pool_recycle w/ 5 mins and also MYSQL database issues a disconnect if there is any connection is open & idle for more than 8 hours, so when this happens and pool creates a new connection then it fails the authentication. We don't see anyway for engine object to reload/refresh/re-read updated credentials other than re-deploying or restarting our services for this issue. Is there any documentation on how we could re-create/reload engine or other mechanisms to handle/address this situation ? Thanks, Pavan. -- SQLAlchemy - The Python SQL Toolkit and Object Relational Mapper http://www.sqlalchemy.org/ To post example code, please provide an MCVE: Minimal, Complete, and Verifiable Example. See http://stackoverflow.com/help/mcve for a full description. --- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To unsubscribe from this group and stop receiving emails from it, send an email to sqlalchemy+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/sqlalchemy/ed50fe16-f759-4d14-a111-62457f4009c5o%40googlegroups.com.