This commit is contained in:
as2252258@163.com
2021-04-08 00:42:18 +08:00
parent 3b01e2dabc
commit 251b3bf6c5
+2 -3
View File
@@ -46,15 +46,14 @@ class OnWorkerStart extends Callback
$annotation->setLoader($runtime); $annotation->setLoader($runtime);
if ($worker_id >= $server->setting['worker_num']) { if ($worker_id >= $server->setting['worker_num']) {
$annotation->runtime(MODEL_PATH); $annotation->instanceDirectoryFiles(MODEL_PATH);
$this->onTask($server, $worker_id); $this->onTask($server, $worker_id);
} else { } else {
$start = microtime(true); $start = microtime(true);
$annotation->runtime(CONTROLLER_PATH); $annotation->instanceDirectoryFiles(APP_PATH);
$annotation->runtime(APP_PATH, CONTROLLER_PATH);
$this->error('use time ' . (microtime(true) - $start)); $this->error('use time ' . (microtime(true) - $start));