From 5a4d007cf95b06dee9e3029dded2d4c6f3d349a4 Mon Sep 17 00:00:00 2001 From: "Richard Kuo (Danswer)" Date: Mon, 10 Feb 2025 15:03:59 -0800 Subject: [PATCH] comments --- backend/onyx/background/celery/tasks/beat_schedule.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/backend/onyx/background/celery/tasks/beat_schedule.py b/backend/onyx/background/celery/tasks/beat_schedule.py index 40db8500c..34a0d26db 100644 --- a/backend/onyx/background/celery/tasks/beat_schedule.py +++ b/backend/onyx/background/celery/tasks/beat_schedule.py @@ -172,10 +172,15 @@ def generate_cloud_tasks( the cloud_beat_task_generator beat_multiplier: a multiplier that can be applied on top of the task schedule to speed up or slow down the task generation rate. useful in production. + + Returns a list of cloud tasks, which consists of incoming tasks + tasks generated + from incoming templates. """ + + # start with the incoming beat tasks cloud_tasks: list[dict] = copy.deepcopy(beat_tasks) - # generate our cloud and self-hosted beat tasks from the templates + # generate our cloud tasks from the templates for beat_template in beat_templates: cloud_task = make_cloud_generator_task(beat_template) cloud_tasks.append(cloud_task)