modify plugin name
This commit is contained in:
+2
-13
@@ -93,19 +93,7 @@ class DatabasesProviders extends Providers
|
|||||||
*/
|
*/
|
||||||
public function check(OnTaskerStart|OnWorkerStart $start): void
|
public function check(OnTaskerStart|OnWorkerStart $start): void
|
||||||
{
|
{
|
||||||
Timer::tick(10000, [$this, 'filter']);
|
Timer::tick(10000, function ($timerId) {
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param $timerId
|
|
||||||
* @return void
|
|
||||||
* @throws ConfigException
|
|
||||||
* @throws ContainerExceptionInterface
|
|
||||||
* @throws NotFoundExceptionInterface
|
|
||||||
*/
|
|
||||||
public function filter($timerId): void
|
|
||||||
{
|
|
||||||
$valid = $count = 0;
|
$valid = $count = 0;
|
||||||
$logger = Kiri::getDi()->get(LoggerInterface::class);
|
$logger = Kiri::getDi()->get(LoggerInterface::class);
|
||||||
$databases = Config::get('databases.connections', []);
|
$databases = Config::get('databases.connections', []);
|
||||||
@@ -117,6 +105,7 @@ class DatabasesProviders extends Providers
|
|||||||
if ($this->container->get(WorkerStatus::class)->is(StatusEnum::EXIT)) {
|
if ($this->container->get(WorkerStatus::class)->is(StatusEnum::EXIT)) {
|
||||||
Timer::clear($timerId);
|
Timer::clear($timerId);
|
||||||
}
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user