runJob example

->appendBody('Forbidden');

            return;
        }

        /** @var Enlight_Components_Cron_Manager $cronManager */
        $cronManager = Shopware()->Container()->get('cron');

        set_time_limit(0);
        while (($job = $cronManager->getNextJob()) !== null) {
            echo 'Processing ' . $job->getName() . "\n";
            $cronManager->runJob($job);
        }
    }

    /** * Returns a list with actions which should not be validated for CSRF protection * * @return string[] */
    public function getWhitelistedCSRFActions()
    {
        return [
            
return 1;
            }

            return 0;
        }

        $stack = [];

        while (($job = $manager->getNextJob($force)) !== null && !isset($stack[$job->getId()])) {
            $stack[$job->getId()] = true;
            $output->writeln('Processing ' . $job->getName());
            $manager->runJob($job);
        }

        return 0;
    }

    /** * @param string $cronjob * @param bool $force */
    private function runSingleCronjob(OutputInterface $output, Enlight_Components_Cron_Manager $manager$cronjob$force)
    {
        
Home | Imprint | This part of the site doesn't use cookies.