Closed xnzdev closed 7 months ago
Hi there,
Thanks for reporting but it looks like this is a question which can be asked on a support channel. Please only use this issue tracker for reporting bugs with the library itself. If you have a question on how to use functionality provided by this repo you can try one of the following channels:
However, this issue will not be locked and everyone is still free to discuss solutions to your problem!
Thanks.
runing the 'php artisan queue:work --queue=a ' command is not a problem. Abort operation when an exception occurs (queue:work). but runing the 'php artisan horizon' infinite loop
Horizon Version
5.9
Laravel Version
9.2
PHP Version
8.0
Redis Driver
PhpRedis
Redis Version
5.3
Database Driver & Version
mysql8.0
Description
当 ImportCsv类中发送异常,horizon 执行队列a 陷入无限循环:
Steps To Reproduce
$batch = Bus::batch([ new ImportCsv(1, 100), new ImportCsv(101, 200) ])->onQueue("a") // take care ->then(function (Batch $batch) { // done })->catch(function (Batch $batch, Throwable $e) { // can not catch })->finally(function (Batch $batch) { // can not exec here })->dispatch();
example:
class ImportCsv implements ShouldQueue{ .... public function handle(){ logger("something!"); $a = null; $b = $a[0]; // make error } }