Exemplo n.º 1
0
 protected function execute(InputInterface $input, OutputInterface $output)
 {
     $this->ids = array();
     if ($id = $input->getOption('id')) {
         $this->ids[] = $id;
         $this->validateState(false);
         $this->validateTube(false);
     }
     parent::execute($input, $output);
     if ($id) {
         $job = $this->getQueue()->peekJob(intval($id));
         $output->writeln("Peeking at job <info>#{$job->getId()}</info>");
         $output->writeln($this->renderJobData($job));
     }
     if ($input->getOption('stats')) {
         $this->renderStats($output, $this->ids);
     }
 }
Exemplo n.º 2
0
 protected function configure()
 {
     parent::configure();
     $this->setName('pause')->setDescription('Pause tubes')->addArgument('delay', InputArgument::OPTIONAL, 'Pause the tube(s) for this many seconds', 0)->addTubeArgument();
 }
Exemplo n.º 3
0
 protected function configure()
 {
     parent::configure();
     $this->setName('delete')->setDescription('Delete jobs')->addTubeArgument()->addStateOptions()->addNumberOption();
 }
Exemplo n.º 4
0
 protected function configure()
 {
     parent::configure();
     $this->setName('bury')->setDescription('Bury jobs')->addTubeArgument()->addNumberOption();
 }
Exemplo n.º 5
0
 protected function configure()
 {
     parent::configure();
     $this->setName('kick')->setDescription('Kick buried and delayed jobs')->addTubeArgument()->addNumberOption();
 }