DEV Community

Garrick Crouch
Garrick Crouch

Posted on

What Does 'queue:listen' actually do in Laravel?

When using the queue command in Laravel you may have noticed that you can do queue:work or queue:listen. The queue:listen command in fact runs this:

php artisan queue:work --once --name=default --queue=default --backoff=0 --memory=128 --sleep=3 --tries=1
Enter fullscreen mode Exit fullscreen mode

As you can see they're the exact same two commands under the hood. The listen just sets some simple options for you, like rebooting the framework on every job, so it makes development easier.

Discussion (0)