|
@@ -89,12 +89,12 @@ class NewContentIdTask(object):
|
|
|
)
|
|
|
# 获取 process_times <= 3 且 content_status = 0 的任务
|
|
|
select_sql = f"""
|
|
|
- SELECT
|
|
|
+ SELECT
|
|
|
trace_id, content_id, flow_pool_level, gh_id, process_times
|
|
|
- FROM
|
|
|
- {self.article_match_video_table}
|
|
|
- WHERE
|
|
|
- content_status = {self.TASK_INIT_STATUS}
|
|
|
+ FROM
|
|
|
+ {self.article_match_video_table}
|
|
|
+ WHERE
|
|
|
+ content_status = {self.TASK_INIT_STATUS}
|
|
|
and process_times <= {self.TASK_MAX_PROCESS_TIMES}
|
|
|
LIMIT {self.spider_coroutines};
|
|
|
"""
|
|
@@ -165,7 +165,7 @@ class NewContentIdTask(object):
|
|
|
SET
|
|
|
content_status = %s,
|
|
|
content_status_update_time = %s,
|
|
|
- process_times = %s,
|
|
|
+ process_times = %s
|
|
|
WHERE trace_id = %s and content_status = %s;
|
|
|
"""
|
|
|
await self.mysql_client.async_insert(
|