dbstructure now switches in the maintenance mode when updating
This commit is contained in:
@@ -29,6 +29,10 @@ function poller_run(&$argv, &$argc){
|
||||
unset($db_host, $db_user, $db_pass, $db_data);
|
||||
};
|
||||
|
||||
// Quit when in maintenance
|
||||
if (get_config('system', 'maintenance', true))
|
||||
return;
|
||||
|
||||
$a->start_process();
|
||||
|
||||
$mypid = getmypid();
|
||||
@@ -71,6 +75,10 @@ function poller_run(&$argv, &$argc){
|
||||
|
||||
while ($r = q("SELECT * FROM `workerqueue` WHERE `executed` = '0000-00-00 00:00:00' ORDER BY `priority`, `created` LIMIT 1")) {
|
||||
|
||||
// Quit when in maintenance
|
||||
if (get_config('system', 'maintenance', true))
|
||||
return;
|
||||
|
||||
// Constantly check the number of parallel database processes
|
||||
if ($a->max_processes_reached())
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user