Fix worker crash by adding activity executor
Build Agents Runtime / build (push) Successful in 4m31s
Details
Build Agents Runtime / build (push) Successful in 4m31s
Details
This commit is contained in:
parent
8dbdce6feb
commit
7c3ad4447b
|
|
@ -4,6 +4,8 @@ from temporalio.worker import Worker
|
|||
from src.orchestrator import CentralOrchestratorWorkflow
|
||||
from src.agent import run_agent_activity
|
||||
|
||||
import concurrent.futures
|
||||
|
||||
async def main():
|
||||
client = await Client.connect("temporal-frontend.ai-core.svc.cluster.local:7233")
|
||||
worker = Worker(
|
||||
|
|
@ -11,6 +13,7 @@ async def main():
|
|||
task_queue="agents-orchestrator",
|
||||
workflows=[CentralOrchestratorWorkflow],
|
||||
activities=[run_agent_activity],
|
||||
activity_executor=concurrent.futures.ThreadPoolExecutor(max_workers=10),
|
||||
)
|
||||
print("Starting worker...")
|
||||
await worker.run()
|
||||
|
|
|
|||
Loading…
Reference in New Issue