|
|
@@ -370,7 +370,8 @@ class TestCommand extends Command
|
|
|
$taskId = $task->id;
|
|
|
$resultUrl = $task->result_url;
|
|
|
|
|
|
- $this->info("处理任务 [{$taskId}] ({$index + 1}/{$total})");
|
|
|
+ $current = $index + 1;
|
|
|
+ $this->info("处理任务 [{$taskId}] ({$current}/{$total})");
|
|
|
|
|
|
try {
|
|
|
// 压缩视频
|
|
|
@@ -409,7 +410,7 @@ class TestCommand extends Command
|
|
|
}
|
|
|
|
|
|
// 每处理10个任务休息一下,避免压力过大
|
|
|
- if (($index + 1) % 10 === 0) {
|
|
|
+ if ($current % 10 === 0) {
|
|
|
sleep(1);
|
|
|
}
|
|
|
}
|
|
|
@@ -454,7 +455,8 @@ class TestCommand extends Command
|
|
|
$segmentId = $segment->segment_id;
|
|
|
$videoTaskId = $segment->video_task_id;
|
|
|
|
|
|
- $this->info("处理分镜 [{$segmentId}] ({$index + 1}/{$total})");
|
|
|
+ $current = $index + 1;
|
|
|
+ $this->info("处理分镜 [{$segmentId}] ({$current}/{$total})");
|
|
|
|
|
|
try {
|
|
|
// 查询对应的视频任务
|
|
|
@@ -502,7 +504,7 @@ class TestCommand extends Command
|
|
|
}
|
|
|
|
|
|
// 每处理10个分镜休息一下
|
|
|
- if (($index + 1) % 10 === 0) {
|
|
|
+ if ($current % 10 === 0) {
|
|
|
sleep(1);
|
|
|
}
|
|
|
}
|