Page MenuHomePhabricator

Provide users a hint that "KILL <process>" is a possible source of connection loss

Authored by epriestley on Oct 24 2018, 5:42 PM.



Ref T13210. See PHI943. When a query fails due to connection loss we currently suggest "wait_timeout" and "max_allowed_packet", but something KILL'ing us also causes this outcome. Add that as a suggestion.

Test Plan

KILL'd a lock three times, got:

$ php -f lock.php 
[2018-10-24 10:40:29] EXCEPTION: (AphrontConnectionLostQueryException) #2006: MySQL server has gone away

This error may occur if your configured MySQL "wait_timeout" or "max_allowed_packet" values are too small. This may also indicate that something used the MySQL "KILL <process>" command to kill the connection running the query. at [<phutil>/src/aphront/storage/connection/mysql/AphrontBaseMySQLDatabaseConnection.php:304]

Diff Detail

rPHU libphutil
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

epriestley created this revision.Oct 24 2018, 5:42 PM
epriestley requested review of this revision.Oct 24 2018, 5:43 PM
amckinley accepted this revision.Oct 26 2018, 1:55 AM
This revision is now accepted and ready to land.Oct 26 2018, 1:55 AM
This revision was automatically updated to reflect the committed changes.