Skip to content

Commit d3bc98c

Browse files
committed
fix(webapp): disable the webhook worker when workers are turned off
WEBHOOK_WORKER_ENABLED defaults from WORKER_ENABLED and follows the same true/false convention as the other worker switches, but the engine compared it to "0" (the convention of a different set of flags). A web-only instance (WORKER_ENABLED=false) therefore kept running webhook delivery jobs once the feature was enabled. Compare against "true" like its peers.
1 parent 65aceb5 commit d3bc98c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

apps/webapp/app/v3/webhookEngine.server.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ function createWebhookEngine() {
5656
tasksPerWorker: env.WEBHOOK_WORKER_CONCURRENCY_TASKS_PER_WORKER,
5757
pollIntervalMs: env.WEBHOOK_WORKER_POLL_INTERVAL,
5858
shutdownTimeoutMs: env.WEBHOOK_WORKER_SHUTDOWN_TIMEOUT_MS,
59-
disabled: env.WEBHOOK_ENABLED !== "1" || env.WEBHOOK_WORKER_ENABLED === "0",
59+
disabled: env.WEBHOOK_ENABLED !== "1" || env.WEBHOOK_WORKER_ENABLED !== "true",
6060
},
6161
partitions: {
6262
ensureSchedule: env.WEBHOOK_PARTITION_ENSURE_SCHEDULE,

0 commit comments

Comments
 (0)