Immediately fail when lock hadn't been acquired to prevent stocked updates

This commit is contained in:
Michael Vogel 2020-11-21 14:17:14 +01:00
parent 2a1c82cf05
commit b40218eb0b

View file

@ -113,7 +113,7 @@ class Update
// Compare the current structure with the defined structure // Compare the current structure with the defined structure
// If the Lock is acquired, never release it automatically to avoid double updates // If the Lock is acquired, never release it automatically to avoid double updates
if (DI::lock()->acquire('dbupdate', 120, Cache\Duration::INFINITE)) { if (DI::lock()->acquire('dbupdate', 0, Cache\Duration::INFINITE)) {
Logger::notice('Update starting.', ['from' => $stored, 'to' => $current]); Logger::notice('Update starting.', ['from' => $stored, 'to' => $current]);