它是 Zend Job Queue 的替代解决方案吗?可以在没有 Zend Server 的情况下使用吗?
我的应用程序需要接受快速请求并提供快速响应(收据)并将这部分限制为数据库条目。之后应在后台执行此附加过程以分析此请求(生成 PDF 文件、发送包含 PDF 的电子邮件、发送短信等),我不想初始请求等待所有这些操作完成 - 只需提供收据并让服务器几秒钟后执行...
Zend Job Queue 将是一个完美的解决方案,但是我现在无法在 Zend Server 环境中努力。
Cron 作业每分钟运行一次不是好方法:(最多 60 秒的延迟,并且每分钟检查数据库是否有新条目,而不是按需)。
你会如何解决这个问题?
Is it alternative solution for Zend Job Queue what could be used without Zend Server ?
My application need to accept quick request and provide quick response (receipt) and limit this part to database entry. After this additional process should be executed in background to analyze this request (generate PDF file, send emails with PDF, send text message, etc) I do not want to initial request to wait for all those actions to finish - just provide receipt and let server do it a few seconds later...
Zend Job Queue would be a perfect solution, however I can not effort Zend Server environment at this moment.
Cron job run every minute is not good way: ( up to 60 seconds delay, and checking database every minute for new entries instead on demand ).
How would you tackle this problem ?
发布评论
评论(2)
以前,我使用 BSD lpd 进行队列管理(在我的例子中,用于对处理 SMS 和传真的调制解调器进行排队访问,而不是用于需求管理)。但还有很多其他工具可用。例如rabbitMQ,Dropr,beanstalkd
Previously I used the BSD lpd for queue management (in my case to queue access for a modem handling SMS and fax, rather than for demand management). But there are lots of other tools available. e.g. rabbitMQ, Dropr, beanstalkd
这是一个老话题,但我也在寻找 zend 队列替代品。
Laravel 队列似乎是最相似的库: https://laravel.com/docs/5.7/queues< /a>
It's an old topic but I wes looking for a zend queue replacement too.
Laravel queues seems to be the most similar library: https://laravel.com/docs/5.7/queues