From 48b47f7903357dca800ea091efea05c27c269a0a Mon Sep 17 00:00:00 2001 From: Josh Date: Sat, 25 May 2024 09:07:43 -0400 Subject: fix(db): Log loong transaction times at debug level Signed-off-by: Josh --- lib/private/DB/Connection.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/private/DB') diff --git a/lib/private/DB/Connection.php b/lib/private/DB/Connection.php index 8bf9e6e99b9..81432d9884f 100644 --- a/lib/private/DB/Connection.php +++ b/lib/private/DB/Connection.php @@ -680,7 +680,7 @@ class Connection extends PrimaryReadReplicaConnection { $timeTook = microtime(true) - $this->transactionActiveSince; $this->transactionActiveSince = null; if ($timeTook > 1) { - $this->logger->warning('Transaction took ' . $timeTook . 's', ['exception' => new \Exception('Transaction took ' . $timeTook . 's')]); + $this->logger->debug('Transaction took ' . $timeTook . 's', ['exception' => new \Exception('Transaction took ' . $timeTook . 's')]); } } return $result; @@ -692,7 +692,7 @@ class Connection extends PrimaryReadReplicaConnection { $timeTook = microtime(true) - $this->transactionActiveSince; $this->transactionActiveSince = null; if ($timeTook > 1) { - $this->logger->warning('Transaction rollback took longer than 1s: ' . $timeTook, ['exception' => new \Exception('Long running transaction rollback')]); + $this->logger->debug('Transaction rollback took longer than 1s: ' . $timeTook, ['exception' => new \Exception('Long running transaction rollback')]); } } return $result; -- cgit v1.2.3