Skip to content

Commit 0a858bc

Browse files
committed
fix(core): retry run start-attempt on transient connection errors
1 parent c72ebf9 commit 0a858bc

2 files changed

Lines changed: 14 additions & 0 deletions

File tree

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@trigger.dev/core": patch
3+
---
4+
5+
Transient connection errors when a run starts are now retried for longer, so a brief connectivity blip no longer sends the run back through the queue and delays its first attempt.

packages/core/src/v3/runEngineWorker/workload/http.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,15 @@ export class WorkloadHttpClient {
165165
...this.defaultHeaders(),
166166
},
167167
body: JSON.stringify(body),
168+
},
169+
{
170+
retry: {
171+
minTimeoutInMs: 1000,
172+
maxTimeoutInMs: 10_000,
173+
maxAttempts: 6,
174+
factor: 2,
175+
randomize: true,
176+
},
168177
}
169178
);
170179
}

0 commit comments

Comments
 (0)