Laravel - Running Jobs in Sequence
问题 I am learning Laravel, working on a project which runs Horizon to learn about jobs. I am stuck at one place where I need to run the same job a few times one after one. Here is what I am currently doing <?php namespace App\Http\Controllers; use App\Http\Controllers\Controller; use App\Models\Subscriptions; class MailController extends Controller { public function sendEmail() { Subscriptions::all() ->each(function($subscription) { SendMailJob::dispatch($subscription); }); } } This works fine,