From 29b341dd803eac18c22367ad12d54fcaece2809d Mon Sep 17 00:00:00 2001 From: Mior Muhammad Zaki Date: Wed, 3 Jan 2024 13:41:44 +0800 Subject: [PATCH] [10.x] Use locks for queue job popping for PlanetScale's MySQL-compatible Vitess 19 engine Signed-off-by: Mior Muhammad Zaki --- src/Illuminate/Queue/DatabaseQueue.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Illuminate/Queue/DatabaseQueue.php b/src/Illuminate/Queue/DatabaseQueue.php index c650f7c480fe..d57f18795d1f 100644 --- a/src/Illuminate/Queue/DatabaseQueue.php +++ b/src/Illuminate/Queue/DatabaseQueue.php @@ -268,7 +268,8 @@ protected function getLockForPopping() if (($databaseEngine === 'mysql' && version_compare($databaseVersion, '8.0.1', '>=')) || ($databaseEngine === 'mariadb' && version_compare($databaseVersion, '10.6.0', '>=')) || - ($databaseEngine === 'pgsql' && version_compare($databaseVersion, '9.5', '>='))) { + ($databaseEngine === 'pgsql' && version_compare($databaseVersion, '9.5', '>=')) || + ($databaseEngine === 'vitess' && version_compare($databaseVersion, '19.0', '>='))) { return 'FOR UPDATE SKIP LOCKED'; }