search([])->map(function (NamiMember $member) use ($api) { return MemberAction::makeJob($api, $member->groupId, $member->id); })->toArray(); $batch = Bus::batch($jobs) // ->then(function (Batch $batch) { // $localMember = InsertMemberAction::run(); // })->catch(function (Batch $batch, Throwable $e) { // // First batch job failure detected... // })->finally(function (Batch $batch) { // // The batch has finished executing... // }) ->dispatch(); try { } catch (Skippable $e) { return; } // app(PullMembershipsAction::class)->handle($localMember); // app(PullCoursesAction::class)->handle($localMember); }); $batch = Bus::batch([ new ImportCsv(1, 100), new ImportCsv(101, 200), new ImportCsv(201, 300), new ImportCsv(301, 400), new ImportCsv(401, 500), } }