This commit is contained in:
2021-04-16 15:43:50 +08:00
parent 167114e150
commit d99d0de646
2 changed files with 4 additions and 4 deletions
+3 -3
View File
@@ -207,9 +207,9 @@ abstract class Crontab extends BaseObject
*/ */
public function execute(): void public function execute(): void
{ {
\Swoole\Coroutine\go(function ($application) { defer(function () {
$application->isRecover($application); $this->isRecover();
}, $this); });
$this->run(); $this->run();
} }
+1 -1
View File
@@ -24,7 +24,7 @@ class Zookeeper extends Process
*/ */
public function onHandler(\Swoole\Process $process): void public function onHandler(\Swoole\Process $process): void
{ {
/** @var \Snowflake\Crontab\Producer $crontab */ /** @var Producer $crontab */
$crontab = Snowflake::app()->get('crontab'); $crontab = Snowflake::app()->get('crontab');
$crontab->clearAll(); $crontab->clearAll();
if (Snowflake::getPlatform()->isLinux()) { if (Snowflake::getPlatform()->isLinux()) {