Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/Illuminate/Queue/Events/QueueFailedOver.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace Illuminate\Queue\Events;

use Throwable;

class QueueFailedOver
{
/**
Expand All @@ -13,6 +15,7 @@ class QueueFailedOver
public function __construct(
public ?string $connectionName,
public mixed $command,
public Throwable $exception,
) {
}
}
4 changes: 2 additions & 2 deletions src/Illuminate/Queue/FailoverQueue.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function push($job, $data = '', $queue = null)
} catch (Throwable $e) {
$lastException = $e;

$this->events->dispatch(new QueueFailedOver($connection, $job));
$this->events->dispatch(new QueueFailedOver($connection, $job, $e));
}
}

Expand Down Expand Up @@ -143,7 +143,7 @@ public function later($delay, $job, $data = '', $queue = null)
} catch (Throwable $e) {
$lastException = $e;

$this->events->dispatch(new QueueFailedOver($connection, $job));
$this->events->dispatch(new QueueFailedOver($connection, $job, $e));
}
}

Expand Down