php - The queue is relatively large, how to handle it with multiple threads
怪我咯
怪我咯 2017-07-04 13:46:21
0
1
981

The length of a queue is 10,000, and it takes about 2 seconds to execute a process. 10,000 items means 20,000 seconds.
If you use contab to execute it every two seconds, it will take almost 6 hours to complete. Is there any way to solve it?

怪我咯
怪我咯

走同样的路,发现不同的人生

reply all(1)
Ty80

Why use crontab?

You can make the consumer queue program into a daemon. If one is not processed in time, several more will be created.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template