mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-07-22 08:05:34 +08:00
update to 2.5.0-b3 (build 410)
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
namespace ZM\Event\SwooleEvent;
|
||||
|
||||
|
||||
use Swoole\Process;
|
||||
use ZM\Annotation\Swoole\SwooleHandler;
|
||||
use ZM\Console\Console;
|
||||
use ZM\Event\SwooleEvent;
|
||||
@@ -16,6 +17,11 @@ use ZM\Event\SwooleEvent;
|
||||
class OnManagerStop implements SwooleEvent
|
||||
{
|
||||
public function onCall() {
|
||||
if (OnManagerStart::$process !== null) {
|
||||
if (Process::kill(OnManagerStart::$process->pid, 0)) {
|
||||
Process::kill(OnManagerStart::$process->pid, SIGTERM);
|
||||
}
|
||||
}
|
||||
Console::verbose("进程 Manager 已停止!");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user