Answer the question
In order to leave comments, you need to log in
Asynchronous job queue for PHP?
I am developing a web site on Yii framework, it is planned that the site will be highly loaded (up to 200,000 per day). I will need to process pictures, send mail, etc. Well, you need to do it asynchronously. I've never experienced this before and don't know what to choose. Suggest something.
UPD : Thanks everyone, I'm leaning towards Gearman but also reading up on RabbitMQ
Answer the question
In order to leave comments, you need to log in
There is a job server - gearman - there was just an article about him recently. PHP works well with it - it can both send tasks to it, and receive and execute it.
3 people per second is not even a very high load.
For desynchronization, you can create a table with tasks in the database (or somewhere else) and then select 10-20 tasks with the crown and process them.
ZeroMq
www.zeromq.org/
Here is a good talk:
www.zfconf.ru/2012/talks/distributed-network-applications-with-zend-framework-2-and-zeromq/
Why bother with something that doesn't exist yet? :)
and about multithreading, you can try this github.com/amal/AzaThread
If your choice still falls on Gearman, I advise you to pay attention to the worker manager github.com/brianlmoon/GearmanManager . We use it on our project, with minor modifications (by the way, also with Yii):
$this->sendComplete($result);
exit(0);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question