Mas logs y middlewares en Guzzle
This commit is contained in:
@ -29,6 +29,7 @@ class BaseLoop extends Console\Command\Command
|
||||
|
||||
$this->waitNextTimeout($output);
|
||||
|
||||
$this->logger->info("Starting loop...");
|
||||
$this->write($output, 'Starting loop...');
|
||||
while (true) {
|
||||
$commands = $this->scheduleService->getPending();
|
||||
|
@ -33,6 +33,7 @@ class Queue extends Command
|
||||
|
||||
$jobs = $this->getJobs($output);
|
||||
if (count($jobs) === 0) {
|
||||
$this->logger->debug("No jobs to run");
|
||||
return Console\Command\Command::SUCCESS;
|
||||
}
|
||||
|
||||
@ -50,6 +51,7 @@ class Queue extends Command
|
||||
$errors = 0;
|
||||
foreach ($jobs as $job) {
|
||||
if ($this->runJob($output, $job) === Console\Command\Command::FAILURE) {
|
||||
$this->logger->error("Error running job: {$job}");
|
||||
$errors ++;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user