Questions tagged [laravel-queue]

Laravel queues provide a unified API across a variety of different queue backends, such as Beanstalk, Amazon SQS, Redis, or even a relational database. Queues allow you to defer the processing of a time-consuming task, such as sending an email, until a later time, drastically speeding up web requests to your application.

Laravel queues provide a unified API across a variety of different queue backends, such as Beanstalk, Amazon SQS, Redis, or even a relational database. Queues allow you to defer the processing of a time-consuming task, such as sending an email, until a later time, drastically speeding up web requests to your application.

448 questions
38
votes
3 answers

Install and configure supervisord on centos 7 to run Laravel queues permanently

I want to use Laravel queue system in my project and I want to run php artisan queue:work permanently on server's background, I did some searches about this and I found a command line which can run it even after quit from ssh terminal but It can be…
Tohid Dadashnezhad
  • 1,808
  • 1
  • 17
  • 27
18
votes
3 answers

How to test Laravel 5 jobs?

I try to catch an event, when job is completed Test code: class MyTest extends TestCase { public function testJobsEvents () { Queue::after(function (JobProcessed $event) { // if ( $job is 'MyJob1' ) then do test …
coder fire
  • 993
  • 2
  • 11
  • 24
16
votes
9 answers

Running laravel queue:work on a shared hosting

I want my laravel queue:work to keep running on a shared hosting, this is a shared hosting (am not on a VPS) I can't install anything because almost all online sources when I was searching for this suggest installing supervisor. So basically I…
lulliezy
  • 1,741
  • 5
  • 24
  • 49
14
votes
2 answers

Google geocoding on the fly using laravel queue

I have about 100 GPS device sending coordinates periodically on every 10 seconds . My customer want real time reverse geocoding to see his vehicles along with location on a tabular view. I have set up a queue to save all those packets in db before…
sumit
  • 15,003
  • 12
  • 69
  • 110
13
votes
3 answers

Laravel queue:restart is not killing workers

I have a laravel 5.4 app deployed via envoyer to a non-forge server. I am running queue workers on the database driver, using supervisor to monitor, setup as described in the docs; command=php /home/data/app/current/artisan queue:work --sleep=3…
Mark Salmon
  • 206
  • 1
  • 2
  • 9
12
votes
1 answer

Laravel queue job doesn't updates to the latest code

I am using a laravel queue job to send emails with an excel attachment. And many a time it is happening, that whenever I update any code change, it doesn't consider the updated code, rather it runs the old code. How can I prevent this?
12
votes
1 answer

Laravel 5.5 - SerializesModels on event causes ModelIdentifier error?

I have a laravel event with a few listeners. Some listeners or their notifications (depending if they are time consuming) are implementing the ShouldQueue so they run in the background on a redis queue. The event uses SerializesModels by default,…
Wonka
  • 8,244
  • 21
  • 73
  • 121
12
votes
1 answer

Laravel Database Queue, "Killed" after a few seconds

i got a problem in my Laravel Project, i'm trying to transcode a video file with FFMPEG about 450MB in size and due to this taking a long time i'm using Queues in Laravel to do this. Due to the configuration of my production environment i have to…
João Serra
  • 509
  • 9
  • 21
12
votes
3 answers

How can I check the status of a queue in Laravel?

I need to submit a number of jobs to a Laravel queue to process some uploaded CSV files. These jobs could be finished in one second if the files are small, or a few seconds if they're bigger, or possibly up to a minute if the CSV files are very big.…
Brendan White
  • 435
  • 2
  • 8
  • 17
11
votes
2 answers

Laravel 7 - Stop Processing Jobs and Clear Queue

I have a production system on AWS and use Laravel Forge. There is a single default queue that is processing Jobs. I've created a number jobs and now wish to delete them (as they take many hours to complete and I realize my input data was bad). I…
BizzyBob
  • 12,309
  • 4
  • 27
  • 51
11
votes
1 answer

Laravel: Unable to JSON encode payload. Error code: 5

I'm working on Laravel (v5.7) app that converts uploaded CSV (with contacts) into array that is then passed as argument when job class is being dispatched. Here is the example of CSV file (format that is…
PeraMika
  • 3,539
  • 9
  • 38
  • 63
11
votes
2 answers

Laravel queue worker with cron

I am trying to get my website to send confirmations emails every time someone new register. i did it like following after reading about it, but i am still not convinced that this is the best way to do it. in my cron runs every minute and calls php…
A. Dabak
  • 760
  • 1
  • 9
  • 23
11
votes
3 answers

How to run a Laravel Job at specify Queue

I have a Job to perform send SMS to user. I want to run this job on the specify queue-name. For example, this job added to "SMS" queue. So I found a way to do this but it's exists some errors. Create job instance and use onQueue() function to do…
Mesuti
  • 878
  • 1
  • 13
  • 29
10
votes
1 answer

The "--queued" option does not exist in Laravel 5.4

I'm going to create Queue job for mailing. once I hit the artisan command in command prompt php artisan make:job SendSMSMessages --queued I got the issue as is follow. The "--queued" option does not exist. I'm using Laravel 5.4 Please anyone can…
HItesh Tank
  • 636
  • 1
  • 6
  • 13
10
votes
6 answers

Laravel queue rate limiting or throttling

I am working on an app that requires fetching data from a third-party server and that server allows max 1 request per seconds. Now, all request send as job and I am trying to implement Laravel "Rate Limiting" to release 1 job per second but unable…
Meathanjay
  • 2,023
  • 1
  • 18
  • 24
1
2 3
29 30