SIENTIAPDE-1646
SIENTIAPDE-1646 Update TemporalManager to consistently assign task queues for runtime workflows, enhancing schedule creation logic and ensuring proper handling of runtime names.
This commit is contained in:
@@ -217,6 +217,8 @@ class TemporalManager(SientiaMonitoring):
|
||||
)
|
||||
|
||||
runtime_name = schedule.get('runtime', 'legacy') if workflow_type in RUNTIME_WORKFLOWS else None
|
||||
task_queue_name = build_queue_name(workflow_type, runtime_name)
|
||||
schedule['task_queue'] = task_queue_name
|
||||
|
||||
await client.create_schedule(
|
||||
schedule_name,
|
||||
@@ -225,9 +227,7 @@ class TemporalManager(SientiaMonitoring):
|
||||
workflow_type,
|
||||
schedule,
|
||||
id=schedule_name,
|
||||
task_queue=build_queue_name(
|
||||
workflow_type, runtime_name
|
||||
),
|
||||
task_queue=task_queue_name,
|
||||
execution_timeout=timedelta(seconds=execution_timeout_seconds),
|
||||
run_timeout=timedelta(seconds=execution_timeout_seconds),
|
||||
task_timeout=timedelta(seconds=task_timeout_seconds),
|
||||
@@ -321,6 +321,10 @@ class TemporalManager(SientiaMonitoring):
|
||||
if not handler:
|
||||
raise ValueError(f'Schedule {schedule_name} not found')
|
||||
|
||||
workflow_type = schedule['workflow_type']
|
||||
runtime_name = schedule.get('runtime', 'legacy') if workflow_type in RUNTIME_WORKFLOWS else None
|
||||
schedule['task_queue'] = build_queue_name(workflow_type, runtime_name)
|
||||
|
||||
# fmt: off
|
||||
async def update_schedule(input_data: ScheduleUpdateInput) -> ScheduleUpdate: # NOSONAR
|
||||
schedule_action = input_data.description.schedule.action
|
||||
|
||||
Reference in New Issue
Block a user