Skip to content
Extraits de code Groupes Projets
Valider f4b87060 rédigé par mattab's avatar mattab
Parcourir les fichiers

Catch exception to let original exception bubble fixes #8871

parent ca01d268
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -708,11 +708,18 @@ class Db ...@@ -708,11 +708,18 @@ class Db
private static function logExtraInfoIfDeadlock($ex) private static function logExtraInfoIfDeadlock($ex)
{ {
if (self::get()->isErrNo($ex, 1213)) { if (!self::get()->isErrNo($ex, 1213)) {
return;
}
try {
$deadlockInfo = self::fetchAll("SHOW ENGINE INNODB STATUS"); $deadlockInfo = self::fetchAll("SHOW ENGINE INNODB STATUS");
// log using exception so backtrace appears in log output // log using exception so backtrace appears in log output
Log::debug(new Exception("Encountered deadlock: " . print_r($deadlockInfo, true))); Log::debug(new Exception("Encountered deadlock: " . print_r($deadlockInfo, true)));
} catch(\Exception $e) {
// 1227 Access denied; you need (at least one of) the PROCESS privilege(s) for this operation
} }
} }
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter