From b2320cdfb7f5debd1ff3968fcc3225deabe691aa Mon Sep 17 00:00:00 2001 From: "mark.tian" Date: Thu, 11 Dec 2025 12:30:28 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=9D=E5=AD=98=E6=B5=8B=E8=AF=95=E9=85=8D?= =?UTF-8?q?=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/celery_app.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/celery_app.py b/app/celery_app.py index 3107ce8..40503c4 100644 --- a/app/celery_app.py +++ b/app/celery_app.py @@ -30,14 +30,15 @@ celery_app.conf.update( worker_max_tasks_per_child=1000, # Beat 调度配置 + # crontab(hour=9, minute=0) # 每天上午9点执行 beat_schedule={ 'push-data-to-dtc-every-minute': { 'task': 'push_data_to_dtc', - 'schedule': 120.0, # 每120秒执行一次(1分钟) + 'schedule': 120.0, # 每120秒执行一次(2分钟) }, 'daily-morning-task': { 'task': 'call_api', - 'schedule': crontab(hour=9, minute=0) # 每天上午9点执行 + 'schedule': 120.0, # 每120秒执行一次(2分钟) }, }, )