Back
Syntax
Study
Editor
Mode:
HTML
CSS
JavaScript
PHP
Reset
Run »
HTML / CSS / JS
# config/queue.php — use Redis driver # 'default' => env('QUEUE_CONNECTION', 'redis'), # Install Horizon # composer require laravel/horizon # php artisan horizon:install # php artisan migrate # config/horizon.php (simplified) # 'environments' => [ # 'production' => [ # 'supervisor-1' => [ # 'connection' => 'redis', # 'queue' => ['high', 'default', 'low'], # 'balance' => 'auto', # 'processes' => 10, # 'tries' => 3, # 'memory' => 128, # ], # ], # ], # Start Horizon (foreground) php artisan horizon # Pause / continue without killing process php artisan horizon:pause php artisan horizon:continue # List failed jobs php artisan queue:failed # Retry a specific failed job php artisan queue:retry <job-id> # Retry all failed jobs php artisan queue:retry all # Flush all failed jobs php artisan queue:flush # Process jobs from a specific queue php artisan queue:work redis --queue=high,default --tries=3 --sleep=3
Result
Open