fixes #2333 avoid deadlock while waiting for user_cache rebuild

This commit is contained in:
plegall committed 2025-03-01 12:04:41 +01:00
1 parent 6489dceadf
commit 5eacda0d76
2 files changed
+21 -2

No files matched your search

+13
View File
@@ -2881,6 +2881,19 @@ INSERT IGNORE
return $exec_id;
}
function pwg_unique_exec_is_running($token_name)
{
$query = '
SELECT
COUNT(*)
FROM '.CONFIG_TABLE.'
WHERE param = "'.$token_name.'_running"
;';
list($counter) = pwg_db_fetch_row(pwg_query($query));
return $counter > 0;
}
function pwg_unique_exec_ends($token_name)
{
conf_delete_param($token_name.'_running');