The "--queued" option is missing in Laravel 5.4

I am going to create a queue job for mailing. as soon as I hit the artisan command on the php artisan make:job SendSMSMessages --queued , I got the problem as shown below.

The --queued option does not exist.

I am using Laravel 5.4

Please someone can help me. I searched a lot, but did not find good solutions.

thanks

+7
php laravel-queue
source share
1 answer

The --queued option was introduced in Laravel 5.0 and remained an option until Laravel 5.1 version https://laravel.com/docs/5.1/queues#writing-job-classes

Starting with Laravel version 5.2, -queued has been removed because by default all newly created jobs are "queued". So your question was about version 5.4, you should create a task without a queue, as shown below:

 artisan make:job SendSMSMessages 

And here is the link to the documentation for Jobs in version 5.4 https://laravel.com/docs/5.4/queues#creating-jobs

+1
source share

All Articles