I've read this question, but apparently the behaviour is still vague. I've a long running process which makes a round each second. During the round I make a request to the DB (select type), then have some processing, eventually saving objects. If the connection is broken for some reason, first of all I get this exception:
django.db.utils.OperationalError: (2013, 'Lost connection to server during query')
I then do nothing about the connection (no closing, no pinging), and on the next round I get this:
django.db.utils.OperationalError: (2006, 'Server has gone away')
The situation repeats ad infinitum, nothing rectifies itself.
Therefore the question: the rumours of django reconnecting itself are not true? I've MAX_CONN_AGE set to 0, and MySQL wait_timeout is default 28800 (in any case since I have a DB request each second, I should never experience that timeout). I would expect django reestablishing the connection if the server is gone, why it's not happening?