Closed
Description
Symfony version(s) affected
5.4.0
Description
Symfony version 5.4.0 introduced a new Symfony\Component\Lock\Store\DoctrineDbalStore
which should be used instead of Symfony\Component\Lock\Store\PdoStore
. In contrast to PdoStore
, the new DoctrineDbalStore
no longer creates the lock table automatically in case it does not exist.
How to reproduce
$factory = new \Symfony\Component\Lock\LockFactory(
new \Symfony\Component\Lock\Store\DoctrineDbalStore('doctrine_url'),
);
$lock = $factory->createLock('test-lock', 300, false);
$lock->acquire();