This commit is contained in:
as2252258@163.com
2021-02-27 02:42:26 +08:00
parent 4cdc11f95b
commit ee4b5065e7
+1 -3
View File
@@ -57,9 +57,8 @@ class OnWorkerStart extends Callback
* @param Server $server
* @param int $workerId
* 异步任务管制
* @return mixed
*/
public function onTaskSignal(Server $server, int $workerId): mixed
public function onTaskSignal(Server $server, int $workerId)
{
$sigkill = Coroutine::waitSignal(SIGTERM | SIGKILL | SIGUSR2 | SIGUSR1, -1);
if ($sigkill !== false) {
@@ -68,7 +67,6 @@ class OnWorkerStart extends Callback
}
}
Snowflake::app()->stateInit();
return $server->stop($workerId);
}