Fix #1705 : MySQL connection might be lost after long operations
Merge pull request #998 from romainneutron/fix-1705

[Ready][3.8] Fix #1705 : MySQL connection might be lost after long operations