Remove hard timeouts and fallback paths in chat flow

This commit is contained in:
Ruslan Bakiev
2026-02-20 10:05:33 +07:00
parent d49b00d688
commit b3602d142e
10 changed files with 49 additions and 99 deletions

View File

@@ -10,7 +10,6 @@ export type OutboundDeliveryJob = {
method?: "POST" | "PUT" | "PATCH";
headers?: Record<string, string>;
payload: unknown;
timeoutMs?: number;
channel?: string;
provider?: string;
};
@@ -119,7 +118,6 @@ export function startOutboundDeliveryWorker() {
}
const endpoint = ensureHttpUrl(job.data.endpoint);
const timeoutMs = Math.max(1000, Math.min(job.data.timeoutMs ?? 20000, 120000));
const method = job.data.method ?? "POST";
const headers: Record<string, string> = {
"content-type": "application/json",
@@ -133,7 +131,6 @@ export function startOutboundDeliveryWorker() {
method,
headers,
body: JSON.stringify(requestPayload ?? {}),
signal: AbortSignal.timeout(timeoutMs),
});
const text = await response.text();