memory check is now also only done once in a while
This commit is contained in:
parent
2b04865cdb
commit
ba7b4fddea
|
@ -96,14 +96,14 @@ function poller_run($argv, $argc){
|
||||||
logger('Active worker limit reached, quitting.', LOGGER_DEBUG);
|
logger('Active worker limit reached, quitting.', LOGGER_DEBUG);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Lock::remove('poller_worker');
|
|
||||||
}
|
|
||||||
|
|
||||||
// Check free memory
|
// Check free memory
|
||||||
if ($a->min_memory_reached()) {
|
if ($a->min_memory_reached()) {
|
||||||
logger('Memory limit reached, quitting.', LOGGER_DEBUG);
|
logger('Memory limit reached, quitting.', LOGGER_DEBUG);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Lock::remove('poller_worker');
|
||||||
|
}
|
||||||
|
|
||||||
// finally the work will be done
|
// finally the work will be done
|
||||||
if (!poller_execute($r[0])) {
|
if (!poller_execute($r[0])) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user