fix(server): release workers when providers stop answering#23854
0 / 10 viewed10 files changedLine totals unavailable
apps/server/src/orchestration-v2/EffectWorker.ts Β· Earlier revision c4966136 Β· right 783
Original diff
@@ -734,7 +778,12 @@ export const layerWithOptions = (
const execution = executor
.execute(effect, { willRetry: effect.attemptCount < maxAttempts })
- .pipe(Effect.as("executed" as const));
+ .pipe(
+ providerTurnControl(effect)
+ ? Effect.timeout(PROVIDER_TURN_CONTROL_EFFECT_TIMEOUT)apps/server/src/orchestration-v2/EffectWorker.ts Β· Earlier revision c4966136 Β· right 782β785
Original diff
@@ -734,7 +778,12 @@ export const layerWithOptions = (
const execution = executor
.execute(effect, { willRetry: effect.attemptCount < maxAttempts })
- .pipe(Effect.as("executed" as const));
+ .pipe(
+ providerTurnControl(effect)
+ ? Effect.timeout(PROVIDER_TURN_CONTROL_EFFECT_TIMEOUT)
+ : identity,
+ Effect.as("executed" as const),apps/server/src/orchestration-v2/EffectWorker.ts Β· right 782β785