freezingsaddles / freezing-sync

Freezing Saddles activity retrieval and processing
Apache License 2.0
1 stars 1 forks source link

MySQL timeouts with long queries #4

Closed hozn closed 6 years ago

hozn commented 6 years ago

http://www.ilian.io/sqlalchemy-and-lost-connection-mysql-server-during-query/

Symptom in the logs (e.g.)

CR.CR_SERVER_LOST, "Lost connection to MySQL server during query") 
Feb 03 07:50:00 freezing-sync freezing-sync: sqlalchemy.exc.OperationalError: (pymysql.err.OperationalError) (2013, 'Lost connection to MySQL server during query') [SQL: 'SELECT athletes.id AS athletes_id, athletes.name AS athletes_name, athletes.display_name AS athletes_display_name, athletes.team_id AS athletes_team_id, athletes.access_token AS athletes_access_token, athletes.profile_photo AS athletes_profile_photo \nFROM athletes \nWHERE athletes.access_token IS NOT NULL AND mod(athletes.id, %(mod_1)s) = %(mod_2)s'] [parameters: {'mod_1': 24, 'mod_2': 12}] (Background on this error at: http://sqlalche.me/e/e3q8)