mirror of
https://github.com/friendica/friendica
synced 2025-04-26 15:10:11 +00:00
Ensure that the daemon is called faster and more reliably
This commit is contained in:
parent
46ea5dc4a5
commit
0edc058a17
2 changed files with 12 additions and 6 deletions
|
@ -1254,6 +1254,11 @@ class Worker
|
|||
DBA::update('workerqueue', ['priority' => $priority], ['parameter' => $parameters, 'done' => false, 'pid' => 0]);
|
||||
}
|
||||
|
||||
// Set the IPC flag to ensure an immediate process execution via daemon
|
||||
if (DI::config()->get('system', 'worker_daemon_mode', false)) {
|
||||
self::IPCSetJobState(true);
|
||||
}
|
||||
|
||||
// Should we quit and wait for the worker to be called as a cronjob?
|
||||
if ($dont_fork) {
|
||||
return $added;
|
||||
|
@ -1272,9 +1277,8 @@ class Worker
|
|||
return $added;
|
||||
}
|
||||
|
||||
// We tell the daemon that a new job entry exists
|
||||
// Quit on daemon mode
|
||||
if (DI::config()->get('system', 'worker_daemon_mode', false)) {
|
||||
// We don't have to set the IPC flag - this is done in "tooMuchWorkers"
|
||||
return $added;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue