isStop() === false) { $read = $process->read(); ActorManager::exec(json_decode($read, true)); Coroutine::sleep(1000 / 120); } } /** * @return $this */ public function onSigterm(): static { // TODO: Implement onSigterm() method. Coroutine::create(function () { $sign = Coroutine::waitSignal(SIGINT | SIGTERM); if ($sign) { $this->onShutdown(true); } }); return $this; } }