[英]queue:listen timeout stop processing queue processing
i'm using laravel 5 queue for render some 3d files with blender. 我正在使用laravel 5队列使用Blender渲染某些3d文件。
some models, have problem with rendering and rendering time is really high like 1 min. 某些模型在渲染方面存在问题,渲染时间确实很高,例如1分钟。
i want to have timeout for doing job (60 sec), when i add timeout to queue:listen , if some job executing time be higher that 60 second , my queue stops but i want just ignore that job and continue doing other jobs. 我想在执行超时(60秒)时将超时添加到queue:listen,如果某项工作的执行时间超过60秒,我的队列会停止,但我只想忽略该工作并继续执行其他工作。
command i ran: 我跑的命令:
php artisan queue:listen --tries=3 --timeout=60
error : 错误:
Symfony\Component\Process\Exception\ProcessTimedOutException]
The process "'/usr/local/php56/bin/php56' 'artisan' queue:work '' --queue='default' --delay=0 --memory=128 --sleep=3 --tries=3 --timeout=120 --env='production'" exceeded the timeout of 60
seconds.
what should i do for solving this ? 我应该怎么做才能解决这个问题?
Edit: 编辑:
I googled supervisor,and i found that supervisor is used to continue queue when any problem happened such rebooting VPS or other problem happening outside of job works. 我搜寻主管,然后发现主管在发生任何问题(例如重新启动VPS或在工作以外发生其他问题)时可以继续排队。
I do n't think supervisor must be used for my problem ... 我不认为必须为我的问题使用主管...
You could use supervisor to restart the process again Laravel docs . 您可以使用超级用户来重新启动Laravel文档 。 You can't really catch a PHP timeout.
您无法真正捕获PHP超时。 Set the tries to 1, so it doesn't attempt the large process.
将trys设置为1,这样就不会尝试大进程。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.