A
A
Andrey Surzhikov2018-11-30 21:04:42
Laravel
Andrey Surzhikov, 2018-11-30 21:04:42

How to organize parallel execution of N tasks in the queue?

Is it possible in Laravel to organize parallel execution of dispatch tasks?
Dispatch created 1500 file parsing tasks.
QUEUE_CONNECTION=database
php artisan queue:work running in terminal
Tasks are executed in turn.
Can it be done in batches of N pieces?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alex Wells, 2018-11-30
@Alex_Wells

Yes, you start several workers (with the same command) and that's it.
PS: Instead of database as a driver, it's better to use beanstalkd.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question