Skip to content

πŸ“¨ The ultimate agentic social media scheduling tool πŸ€–

fix(worker): make non-"main" Temporal Workers activity-only

Gilad Resisi6e1c103e2b4d
diff --git a/libraries/nestjs-libraries/src/temporal/temporal.module.ts b/libraries/nestjs-libraries/src/temporal/temporal.module.ts
index 85c54bfd8..e91318e6f 100644
--- a/libraries/nestjs-libraries/src/temporal/temporal.module.ts
+++ b/libraries/nestjs-libraries/src/temporal/temporal.module.ts
@@ -59,9 +59,12 @@ export const getTemporalModule = (
)
: undefined;
+ // Workflows only ever run on the `main` queue; the other Workers
+ // are activity-only, so skip the workflow bundle (webpack build,
+ // workflow thread + V8 isolate, sticky cache) on them.
return {
taskQueue,
- workflowsPath: path!,
+ ...(taskQueue === 'main' ? { workflowsPath: path! } : {}),
activityClasses: activityClasses!,
autoStart: true,
...(concurrency