***的方法是将作业添加到队列中,让服务器处理ffmpeg以异步方式转换。
The best way is to add a job to a queue and let the server handle the ffmpeg conversion in asynchronous way.
用户必须手动重新检查服务器是否已经完成该作业。
The users has to manually recheck if the server has already finished the job.
你必须这样做:
- 创建一个队列数据库表。
- 如果新的ffmpeg转换应该在队列表中添加一个作业。
- 在服务器上添加一个自动寻找新作业并执行ffmpeg转换的cronjob。 此处有更多细节
- 当cronjob完成转换,然后标记作业完成,删除它或任何。
- Create a queue database table.
- If a new ffmpeg conversion should be done add a job to the queue table.
- On the server add a cronjob which automatically looks for new jobs and executes your ffmpeg conversion. More details here.
- When the cronjob has finished the conversion then mark the job as done, delete it, or whatever.