A cheap, but effective queue implementation for Laravel
A cheap, but effective queue implementation for Laravel. Easy to install like the sync driver, but more performant for the end-user.
This is achieved by registering jobs as shutdown functions, which means that they will only be executed once the application has sent its response to the client
NOTE: This driver does not support the
release() methods for jobs. They can be called, but will not have any effect. Jobs will be deleted automatically after being run, and releasing them will not run them again.
Add this line to the
require section of your
Alternately, you can use the Composer command-line tool by running this command:
composer require franzl/tardiqueue:1.1.x
composer install to actually install the package.
In your Laravel application, edit the
app/config/app.php file and add this
line to the
In your application, edit the
app/config/queue.php file and add a new connection using the
delayed driver, like so:
'delayed' => array( 'driver' => 'delayed', ),
To actually make this your default queue, set the
default option to
Once installed, you can use Laravel's queue feature as you always do. Tardiqueue will then make sure all your queued jobs are run at the end of each request, so that the client can already start rendering while your server is lifting some heavy tasks.