|
@@ -303,6 +303,21 @@ class Response(object):
|
|
|
"message": "该任务正在执行中"
|
|
|
}
|
|
|
|
|
|
+ async def check_trace_id(self):
|
|
|
+ """
|
|
|
+ check trace id 是否存在与系统中
|
|
|
+ """
|
|
|
+ select_sql = f"""
|
|
|
+ SELECT trace_id
|
|
|
+ FROM {self.article_match_video_table}
|
|
|
+ WHERE trace_id = '{self.trace_id}';
|
|
|
+ """
|
|
|
+ response = await self.mysql_client.async_select(select_sql)
|
|
|
+ if response:
|
|
|
+ return True
|
|
|
+ else:
|
|
|
+ return False
|
|
|
+
|
|
|
async def deal(self):
|
|
|
"""
|
|
|
api process starts from here
|