Django doesn't commit changes to MySQL database
Django doesn't commit changes to MySQL database
My web-app is deployed on two different VPS on different subnets, one for Django and the other for database.
the problem is that whenever i send a request to app-server it takes about 10 second to get response (waiting time) and as I noticed, this time is just for connecting to database-server (meking query). i have no idea how to fix it , in Django database setting, i set the 'CONN_MAX_AGE' parameter to None and now the response time is OK! but Django doesn't commit any change that i make on database and as you restart the app server all the changes rolls back! does anyone has an idea about?
thanks
DATABASES
all the changes rolls back
- so those changes actually existed in the database? Otherwise where were they rolled back from? whenever i send a request to server it takes about 10 second to get response
- which server is that? MySQL or Django app/gunicorn? Who is slow?– Ivan Starostin
Aug 21 at 4:43
all the changes rolls back
whenever i send a request to server it takes about 10 second to get response
By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.
Can you included your
DATABASES
configuration from your settings (remove the host, username, and password)?– FlipperPA
Aug 20 at 22:48