分布式任务调整

This commit is contained in:
dongchangxi committed 2023-10-31 19:55:28 +08:00
1 parent fe9c6e6267
commit 57831c7167
11 files changed
+224 -96

No files matched your search

+3 -1
View File
@@ -61,6 +61,7 @@ def base_fix(pid):
start_time = time.time()
# 统一文件名规则
def fix_filename(pid):
texture_filename_end = ""
if os.path.exists(os.path.join(config.workdir, pid, 'output', f'{pid}.jpg')):
print(f'{time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())} pid: {pid} 已经是最新文件名规则,无需处理')
return
@@ -214,7 +215,8 @@ def step3(pid,task_distributed_id=""):
#更新主表的status 和 finished_at
main_service_db.update_task_distributed({"id":task_distributed_id,"status":2,"finished_at":time.strftime("%Y-%m-%d %H:%M:%S", time.localtime())})
return
print("step3 已执行完成")
#return
def main(pid):
if pid == '0':