From 9af5b097020218fdfc335f2516bc39a4ba901e48 Mon Sep 17 00:00:00 2001 From: "as2252258@163.com" Date: Fri, 16 Apr 2021 01:17:37 +0800 Subject: [PATCH] modify --- System/Crontab/Zookeeper.php | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/System/Crontab/Zookeeper.php b/System/Crontab/Zookeeper.php index 8d0e1c01..2fc7a45f 100644 --- a/System/Crontab/Zookeeper.php +++ b/System/Crontab/Zookeeper.php @@ -8,9 +8,7 @@ use Exception; use Snowflake\Cache\Redis; use Snowflake\Process\Process; use Snowflake\Snowflake; -use Swoole\Coroutine\Channel; -use Swoole\Coroutine\WaitGroup; -use Swoole\Timer; +use Throwable; /** * Class Zookeeper @@ -19,14 +17,6 @@ use Swoole\Timer; class Zookeeper extends Process { - /** @var Crontab[] $names */ - public array $names = []; - - - public array $scores = []; - public array $timers = []; - - /** * @param \Swoole\Process $process * @throws Exception @@ -71,7 +61,7 @@ class Zookeeper extends Process $result = $server->sendMessage($params, $workerId = random_int(0, $setting - 1)); var_dump('send crontab to ' . $workerId . ' ' . intval($result)); - } catch (\Throwable $exception) { + } catch (Throwable $exception) { logger()->addError($exception); }