FroshTools icon indicating copy to clipboard operation
FroshTools copied to clipboard

Make statuses configurable in TaskChecker

Open alessandroaussems opened this issue 6 months ago • 1 comments

Please describe the feature you would like to see implemented.

Often we move a scheduled task that has an console command equivalent to crontab of the server. Since crontab is easier to monitor and more reliable than the Shopware scheduled tasks with the scheduled_task table.

If we do so we assign the scheduled_task the status 'crontab' to indicate the process runs from crontab.

It would be nice if the statuses you want to ignore are configurable.

Pseudo code:

$data = $this->connection->createQueryBuilder()
      ->select('s.scheduled_task_class', 's.next_execution_time')
      ->from('scheduled_task', 's')
      ->where('s.status NOT IN(:status)')
      ->setParameter('status', $this->configService->getArray('FroshTools.config.monitorTaskList'), ArrayParameterType::STRING)
      ->fetchAllAssociative();

alessandroaussems avatar Aug 14 '24 07:08 alessandroaussems