info(sprintf('服务运行ID : %s', SERVER_RUN_ID)); $this->setTimeOut(); Timer::tick(15000, function () { $this->setTimeOut(); }); } public function setTimeOut() { container()->get(Redis::class)->hset('SERVER_RUN_ID', SERVER_RUN_ID, time()); } }