Skip to content

🪢 Open source agent evals & observability: Trace, evaluate, and improve LLM applications with one open platform.

chore(blob-export): add chSendTimeout ClickHouse export tuning (#14625)

Niklas Semmler050a997f0826
diff --git a/packages/shared/src/features/analytics-integrations/blob-export-tuning.test.ts b/packages/shared/src/features/analytics-integrations/blob-export-tuning.test.ts
index 6ffa9099c5..53a9f9efe1 100644
--- a/packages/shared/src/features/analytics-integrations/blob-export-tuning.test.ts
+++ b/packages/shared/src/features/analytics-integrations/blob-export-tuning.test.ts
@@ -27,6 +27,7 @@ function resolved(
maxConcurrentParts: undefined,
maxPartAttempts: undefined,
skipEnrichment: false,
+ chSendTimeout: undefined,
...overrides,
};
}
@@ -232,6 +233,56 @@ describe("resolveBlobExportTuning", () => {
});
});
+ describe("chSendTimeout (ClickHouse send_timeout)", () => {
+ it("is undefined (CH default) when absent", () => {
+ expect(
+ resolveBlobExportTuning({}, DEFAULTS).resolved.chSendTimeout,
+ ).toBeUndefined();
+ });
+
+ it("honors an in-range value silently", () => {
+ const { resolved: res, warnings } = resolveBlobExportTuning(
+ { chSendTimeout: 600 },
+ DEFAULTS,
+ );
+ expect(res).toEqual(resolved({ chSendTimeout: 600 }));
+ expect(warnings).toEqual([]);
+ });
+
+ it("clamps above the ceiling and warns", () => {
+ const { resolved: res, warnings } = resolveBlobExportTuning(
+ { chSendTimeout: 99999 },
+ DEFAULTS,
+ );
+ expect(res.chSendTimeout).toBe(
+ BLOB_EXPORT_TUNING_BOUNDS.chSendTimeout.max,
+ );
+ expect(warnings.some((w) => w.includes("clamped"))).toBe(true);
+ });
+
+ it("clamps below the floor and warns", () => {
+ const { resolved: res, warnings } = resolveBlobExportTuning(
+ { chSendTimeout: 0 },
+ DEFAULTS,
+ );
+ expect(res.chSendTimeout).toBe(
+ BLOB_EXPORT_TUNING_BOUNDS.chSendTimeout.min,
+ );
+ expect(warnings.some((w) => w.includes("clamped"))).toBe(true);
+ });
+
+ it("falls back to undefined (CH default) when wrong-typed", () => {
+ const { resolved: res, warnings } = resolveBlobExportTuning(
+ { chSendTimeout: "300" },
+ DEFAULTS,
+ );
+ expect(res.chSendTimeout).toBeUndefined();
+ expect(warnings.some((w) => w.includes("expected a finite number"))).toBe(
+ true,
+ );
+ });
+ });
+
describe("valid in-range upload knobs are honoured silently", () => {
it("passes through values within bounds", () => {
const { resolved: res, warnings } = resolveBlobExportTuning(
@@ -400,6 +451,12 @@ describe("BlobExportTuningSchema (write schema)", () => {
);
});
+ it("accepts an in-range chSendTimeout", () => {
+ expect(
+ BlobExportTuningSchema.safeParse({ chSendTimeout: 600 }).success,
+ ).toBe(true);
+ });
+
it("rejects out-of-range values (writes reject; reads clamp)", () => {
expect(
BlobExportTuningSchema.safeParse({ maxConcurrentParts: 50 }).success,
@@ -407,6 +464,9 @@ describe("BlobExportTuningSchema (write schema)", () => {
expect(BlobExportTuningSchema.safeParse({ gzipLevel: 12 }).success).toBe(
false,
);
+ expect(
+ BlobExportTuningSchema.safeParse({ chSendTimeout: 99999 }).success,
+ ).toBe(false);
});
it("strips unknown keys (forward-compat, not strict)", () => {
diff --git a/packages/shared/src/features/analytics-integrations/blob-export-tuning.ts b/packages/shared/src/features/analytics-integrations/blob-export-tuning.ts
index 14d9728c39..10044e4c27 100644
--- a/packages/shared/src/features/analytics-integrations/blob-export-tuning.ts
+++ b/packages/shared/src/features/analytics-integrations/blob-export-tuning.ts
@@ -44,6 +44,9 @@ export const BLOB_EXPORT_TUNING_BOUNDS = {
partSizeBytes: { min: 5 * 1024 * 1024, max: 5 * 1024 * 1024 * 1024 },
maxConcurrentParts: { min: 1, max: 32 },
maxPartAttempts: { min: 1, max: 10 },
+ // ClickHouse `send_timeout` (seconds) applied to the export query. CH's default
+ // is 300s; allow 1s..1h for per-project tuning of long-running exports.
+ chSendTimeout: { min: 1, max: 3600 },
} as const;
// Default part size when the column does not specify one. Matches the value
@@ -94,6 +97,16 @@ export const BlobExportTuningSchema = z.object({
.max(BLOB_EXPORT_TUNING_BOUNDS.maxPartAttempts.max)
.optional(),
skipEnrichment: z.boolean().optional(),
+ // ClickHouse `send_timeout` (seconds) for the export query, passed through as a
+ // per-query clickhouse_setting. Absent => CH keeps its own default (300s).
+ // Out-of-range values are REJECTED here (write path) but CLAMPED by the
+ // read-side resolver.
+ chSendTimeout: z
+ .number()
+ .int()
+ .min(BLOB_EXPORT_TUNING_BOUNDS.chSendTimeout.min)
+ .max(BLOB_EXPORT_TUNING_BOUNDS.chSendTimeout.max)
+ .optional(),
});
export type BlobExportTuning = z.infer<typeof BlobExportTuningSchema>;
@@ -119,6 +132,9 @@ export type ResolvedBlobExportTuning = {
maxConcurrentParts: number | undefined;
maxPartAttempts: number | undefined;
skipEnrichment: boolean;
+ // undefined => not set by the operator; ClickHouse keeps its own send_timeout
+ // default (300s). A concrete value (seconds) is applied per-query.
+ chSendTimeout: number | undefined;
};
export interface ResolveBlobExportTuningResult {
@@ -257,6 +273,7 @@ export function resolveBlobExportTuning(
maxConcurrentParts: undefined,
maxPartAttempts: undefined,
skipEnrichment: false,
+ chSendTimeout: undefined,
};
if (raw === null || raw === undefined) {
@@ -320,6 +337,12 @@ export function resolveBlobExportTuning(
obj.skipEnrichment,
warnings,
),
+ chSendTimeout: resolveOptionalNumber(
+ "chSendTimeout",
+ obj.chSendTimeout,
+ BLOB_EXPORT_TUNING_BOUNDS.chSendTimeout,
+ warnings,
+ ),
},
warnings,
};
diff --git a/packages/shared/src/server/repositories/events.ts b/packages/shared/src/server/repositories/events.ts
index 398e775669..1691779c6c 100644
--- a/packages/shared/src/server/repositories/events.ts
+++ b/packages/shared/src/server/repositories/events.ts
@@ -2668,6 +2668,7 @@ const buildEventsForBlobStorageExportQuery = (
maxTimestamp: Date,
fieldGroups: ObservationFieldGroupFull[],
convertLatencyToSecondsInSql: boolean,
+ chSendTimeout?: number,
) => {
const queryBuilder = new EventsQueryBuilder({ projectId });
@@ -2709,6 +2710,9 @@ const buildEventsForBlobStorageExportQuery = (
clickhouseConfigs: {
request_timeout: env.LANGFUSE_CLICKHOUSE_DATA_EXPORT_REQUEST_TIMEOUT_MS,
},
+ // Per-project ClickHouse send_timeout (seconds); undefined => CH default.
+ clickhouseSettings:
+ chSendTimeout !== undefined ? { send_timeout: chSendTimeout } : undefined,
preferredClickhouseService: "EventsReadOnly" as const,
};
};
@@ -2718,6 +2722,7 @@ export const getEventsForBlobStorageExport = function (
minTimestamp: Date,
maxTimestamp: Date,
fieldGroups: ObservationFieldGroupFull[] = [...OBSERVATION_FIELD_GROUPS_FULL],
+ chSendTimeout?: number,
) {
return queryClickhouseStream<Record<string, unknown>>(
buildEventsForBlobStorageExportQuery(
@@ -2726,6 +2731,7 @@ export const getEventsForBlobStorageExport = function (
maxTimestamp,
fieldGroups,
false, // standard path converts latency ms→s in JS
+ chSendTimeout,
),
);
};
@@ -2741,6 +2747,7 @@ export const getEventsForBlobStorageExportRaw = function (
maxTimestamp: Date,
fieldGroups: ObservationFieldGroupFull[] = [...OBSERVATION_FIELD_GROUPS_FULL],
convertLatencyToSeconds = false,
+ chSendTimeout?: number,
) {
return queryClickhouseStreamRawText(
buildEventsForBlobStorageExportQuery(
@@ -2749,6 +2756,7 @@ export const getEventsForBlobStorageExportRaw = function (
maxTimestamp,
fieldGroups,
convertLatencyToSeconds,
+ chSendTimeout,
),
);
};
@@ -2762,17 +2770,24 @@ export const getEventsForBlobStorageExportParquet = function (
maxTimestamp: Date,
fieldGroups: ObservationFieldGroupFull[] = [...OBSERVATION_FIELD_GROUPS_FULL],
convertLatencyToSeconds = false,
+ chSendTimeout?: number,
) {
+ const base = buildEventsForBlobStorageExportQuery(
+ projectId,
+ minTimestamp,
+ maxTimestamp,
+ fieldGroups,
+ convertLatencyToSeconds,
+ chSendTimeout,
+ );
return queryClickhouseExecRaw({
- ...buildEventsForBlobStorageExportQuery(
- projectId,
- minTimestamp,
- maxTimestamp,
- fieldGroups,
- convertLatencyToSeconds,
- ),
+ ...base,
format: "Parquet",
- clickhouseSettings: BLOB_EXPORT_PARQUET_CLICKHOUSE_SETTINGS,
+ // Merge so the per-project send_timeout survives alongside Parquet tuning.
+ clickhouseSettings: {
+ ...base.clickhouseSettings,
+ ...BLOB_EXPORT_PARQUET_CLICKHOUSE_SETTINGS,
+ },
});
};
diff --git a/packages/shared/src/server/repositories/observations.ts b/packages/shared/src/server/repositories/observations.ts
index b4b29eefe8..784c89e5b6 100644
--- a/packages/shared/src/server/repositories/observations.ts
+++ b/packages/shared/src/server/repositories/observations.ts
@@ -1704,6 +1704,7 @@ const buildObservationsForBlobStorageExportQuery = (
minTimestamp: Date,
maxTimestamp: Date,
fieldGroups: ObservationFieldGroupFull[],
+ chSendTimeout?: number,
) => {
// core is always required (provides id, trace_id, start/end_time used for deduplication)
const effectiveGroups = new Set<ObservationFieldGroupFull>([
@@ -1741,6 +1742,9 @@ const buildObservationsForBlobStorageExportQuery = (
clickhouseConfigs: {
request_timeout: env.LANGFUSE_CLICKHOUSE_DATA_EXPORT_REQUEST_TIMEOUT_MS,
},
+ // Per-project ClickHouse send_timeout (seconds); undefined => CH default.
+ clickhouseSettings:
+ chSendTimeout !== undefined ? { send_timeout: chSendTimeout } : undefined,
preferredClickhouseService: "ReadOnly" as const,
};
};
@@ -1750,6 +1754,7 @@ export const getObservationsForBlobStorageExport = function (
minTimestamp: Date,
maxTimestamp: Date,
fieldGroups: ObservationFieldGroupFull[] = [...OBSERVATION_FIELD_GROUPS_FULL],
+ chSendTimeout?: number,
) {
return queryClickhouseStream<Record<string, unknown>>(
buildObservationsForBlobStorageExportQuery(
@@ -1757,6 +1762,7 @@ export const getObservationsForBlobStorageExport = function (
minTimestamp,
maxTimestamp,
fieldGroups,
+ chSendTimeout,
),
);
};
@@ -1769,6 +1775,7 @@ export const getObservationsForBlobStorageExportRaw = function (
minTimestamp: Date,
maxTimestamp: Date,
fieldGroups: ObservationFieldGroupFull[] = [...OBSERVATION_FIELD_GROUPS_FULL],
+ chSendTimeout?: number,
) {
return queryClickhouseStreamRawText(
buildObservationsForBlobStorageExportQuery(
@@ -1776,6 +1783,7 @@ export const getObservationsForBlobStorageExportRaw = function (
minTimestamp,
maxTimestamp,
fieldGroups,
+ chSendTimeout,
),
);
};
@@ -1788,16 +1796,23 @@ export const getObservationsForBlobStorageExportParquet = function (
minTimestamp: Date,
maxTimestamp: Date,
fieldGroups: ObservationFieldGroupFull[] = [...OBSERVATION_FIELD_GROUPS_FULL],
+ chSendTimeout?: number,
) {
+ const base = buildObservationsForBlobStorageExportQuery(
+ projectId,
+ minTimestamp,
+ maxTimestamp,
+ fieldGroups,
+ chSendTimeout,
+ );
return queryClickhouseExecRaw({
- ...buildObservationsForBlobStorageExportQuery(
- projectId,
- minTimestamp,
- maxTimestamp,
- fieldGroups,
- ),
+ ...base,
format: "Parquet",
- clickhouseSettings: BLOB_EXPORT_PARQUET_CLICKHOUSE_SETTINGS,
+ // Merge so the per-project send_timeout survives alongside Parquet tuning.
+ clickhouseSettings: {
+ ...base.clickhouseSettings,
+ ...BLOB_EXPORT_PARQUET_CLICKHOUSE_SETTINGS,
+ },
});
};
diff --git a/packages/shared/src/server/repositories/scores.ts b/packages/shared/src/server/repositories/scores.ts
index c8d07e9384..e96268fa78 100644
--- a/packages/shared/src/server/repositories/scores.ts
+++ b/packages/shared/src/server/repositories/scores.ts
@@ -1912,6 +1912,7 @@ const buildScoresForBlobStorageExportQuery = (
projectId: string,
minTimestamp: Date,
maxTimestamp: Date,
+ chSendTimeout?: number,
) => {
const query = `
SELECT
@@ -1951,6 +1952,9 @@ const buildScoresForBlobStorageExportQuery = (
clickhouseConfigs: {
request_timeout: env.LANGFUSE_CLICKHOUSE_DATA_EXPORT_REQUEST_TIMEOUT_MS,
},
+ // Per-project ClickHouse send_timeout (seconds); undefined => CH default.
+ clickhouseSettings:
+ chSendTimeout !== undefined ? { send_timeout: chSendTimeout } : undefined,
};
};
@@ -1958,9 +1962,15 @@ export const getScoresForBlobStorageExport = function (
projectId: string,
minTimestamp: Date,
maxTimestamp: Date,
+ chSendTimeout?: number,
) {
return queryClickhouseStream<Record<string, unknown>>(
- buildScoresForBlobStorageExportQuery(projectId, minTimestamp, maxTimestamp),
+ buildScoresForBlobStorageExportQuery(
+ projectId,
+ minTimestamp,
+ maxTimestamp,
+ chSendTimeout,
+ ),
);
};
@@ -1970,15 +1980,22 @@ export const getScoresForBlobStorageExportParquet = function (
projectId: string,
minTimestamp: Date,
maxTimestamp: Date,
+ chSendTimeout?: number,
) {
+ const base = buildScoresForBlobStorageExportQuery(
+ projectId,
+ minTimestamp,
+ maxTimestamp,
+ chSendTimeout,
+ );
return queryClickhouseExecRaw({
- ...buildScoresForBlobStorageExportQuery(
- projectId,
- minTimestamp,
- maxTimestamp,
- ),
+ ...base,
format: "Parquet",
- clickhouseSettings: BLOB_EXPORT_PARQUET_CLICKHOUSE_SETTINGS,
+ // Merge so the per-project send_timeout survives alongside Parquet tuning.
+ clickhouseSettings: {
+ ...base.clickhouseSettings,
+ ...BLOB_EXPORT_PARQUET_CLICKHOUSE_SETTINGS,
+ },
});
};
diff --git a/packages/shared/src/server/repositories/traces.ts b/packages/shared/src/server/repositories/traces.ts
index 650d84e179..805e396f98 100644
--- a/packages/shared/src/server/repositories/traces.ts
+++ b/packages/shared/src/server/repositories/traces.ts
@@ -1280,6 +1280,7 @@ const buildTracesForBlobStorageExportQuery = (
projectId: string,
minTimestamp: Date,
maxTimestamp: Date,
+ chSendTimeout?: number,
) => {
const traceTable = "traces";
@@ -1320,6 +1321,9 @@ const buildTracesForBlobStorageExportQuery = (
clickhouseConfigs: {
request_timeout: env.LANGFUSE_CLICKHOUSE_DATA_EXPORT_REQUEST_TIMEOUT_MS,
},
+ // Per-project ClickHouse send_timeout (seconds); undefined => CH default.
+ clickhouseSettings:
+ chSendTimeout !== undefined ? { send_timeout: chSendTimeout } : undefined,
};
};
@@ -1327,9 +1331,15 @@ export const getTracesForBlobStorageExport = function (
projectId: string,
minTimestamp: Date,
maxTimestamp: Date,
+ chSendTimeout?: number,
) {
return queryClickhouseStream<Record<string, unknown>>(
- buildTracesForBlobStorageExportQuery(projectId, minTimestamp, maxTimestamp),
+ buildTracesForBlobStorageExportQuery(
+ projectId,
+ minTimestamp,
+ maxTimestamp,
+ chSendTimeout,
+ ),
);
};
@@ -1339,15 +1349,22 @@ export const getTracesForBlobStorageExportParquet = function (
projectId: string,
minTimestamp: Date,
maxTimestamp: Date,
+ chSendTimeout?: number,
) {
+ const base = buildTracesForBlobStorageExportQuery(
+ projectId,
+ minTimestamp,
+ maxTimestamp,
+ chSendTimeout,
+ );
return queryClickhouseExecRaw({
- ...buildTracesForBlobStorageExportQuery(
- projectId,
- minTimestamp,
- maxTimestamp,
- ),
+ ...base,
format: "Parquet",
- clickhouseSettings: BLOB_EXPORT_PARQUET_CLICKHOUSE_SETTINGS,
+ // Merge so the per-project send_timeout survives alongside Parquet tuning.
+ clickhouseSettings: {
+ ...base.clickhouseSettings,
+ ...BLOB_EXPORT_PARQUET_CLICKHOUSE_SETTINGS,
+ },
});
};
diff --git a/worker/src/__tests__/blobStorageTuningWiring.unit.test.ts b/worker/src/__tests__/blobStorageTuningWiring.unit.test.ts
index eb65c856f2..aa23d4d494 100644
--- a/worker/src/__tests__/blobStorageTuningWiring.unit.test.ts
+++ b/worker/src/__tests__/blobStorageTuningWiring.unit.test.ts
@@ -4,6 +4,10 @@ import { Readable } from "stream";
// Records of every uploadFileBuffered call so we can assert the resolved tuning
// was threaded through. Hoisted so the module mock can close over it.
const uploadCalls = vi.hoisted(() => [] as any[]);
+// Records (fnName, args) for each standard-path export getter call so we can
+// assert tuning that targets the ClickHouse query (e.g. chSendTimeout) is
+// threaded all the way down.
+const exportCalls = vi.hoisted(() => [] as { fn: string; args: any[] }[]);
vi.mock("@langfuse/shared/src/db", () => ({
prisma: {
@@ -36,10 +40,22 @@ vi.mock("@langfuse/shared/src/server", async (importOriginal) => {
}),
}),
},
- getTracesForBlobStorageExport: () => empty(),
- getObservationsForBlobStorageExport: () => empty(),
- getScoresForBlobStorageExport: () => empty(),
- getEventsForBlobStorageExport: () => empty(),
+ getTracesForBlobStorageExport: (...args: any[]) => {
+ exportCalls.push({ fn: "traces", args });
+ return empty();
+ },
+ getObservationsForBlobStorageExport: (...args: any[]) => {
+ exportCalls.push({ fn: "observations", args });
+ return empty();
+ },
+ getScoresForBlobStorageExport: (...args: any[]) => {
+ exportCalls.push({ fn: "scores", args });
+ return empty();
+ },
+ getEventsForBlobStorageExport: (...args: any[]) => {
+ exportCalls.push({ fn: "events", args });
+ return empty();
+ },
// LFE-10463 Parquet path: each returns an already-resolved
// { stream } (the binary body) — a tiny Readable with the Parquet magic.
getTracesForBlobStorageExportParquet: async () => ({
@@ -108,9 +124,38 @@ function baseRow(exportTuning: unknown) {
describe("handleBlobStorageIntegrationProjectJob tuning wiring", () => {
beforeEach(() => {
uploadCalls.length = 0;
+ exportCalls.length = 0;
vi.clearAllMocks();
});
+ it("threads chSendTimeout into the standard export query", async () => {
+ (prisma.blobStorageIntegration.findUnique as any).mockResolvedValue(
+ baseRow({ chSendTimeout: 600 }),
+ );
+
+ await handleBlobStorageIntegrationProjectJob(makeJob());
+
+ // Standard-path getters take chSendTimeout as the last positional arg:
+ // traces/scores at index 3, observations (fieldGroups before it) at index 4.
+ const traces = exportCalls.find((c) => c.fn === "traces");
+ expect(traces?.args[3]).toBe(600);
+ const scores = exportCalls.find((c) => c.fn === "scores");
+ expect(scores?.args[3]).toBe(600);
+ const observations = exportCalls.find((c) => c.fn === "observations");
+ expect(observations?.args[4]).toBe(600);
+ });
+
+ it("passes chSendTimeout=undefined when unset (ClickHouse keeps its default)", async () => {
+ (prisma.blobStorageIntegration.findUnique as any).mockResolvedValue(
+ baseRow(null),
+ );
+
+ await handleBlobStorageIntegrationProjectJob(makeJob());
+
+ const traces = exportCalls.find((c) => c.fn === "traces");
+ expect(traces?.args[3]).toBeUndefined();
+ });
+
it("clamps out-of-range tuning and threads it into uploadFileBuffered", async () => {
(prisma.blobStorageIntegration.findUnique as any).mockResolvedValue(
baseRow({
diff --git a/worker/src/features/blobstorage/handleBlobStorageIntegrationProjectJob.ts b/worker/src/features/blobstorage/handleBlobStorageIntegrationProjectJob.ts
index 67cf3f9fb7..71f6243680 100644
--- a/worker/src/features/blobstorage/handleBlobStorageIntegrationProjectJob.ts
+++ b/worker/src/features/blobstorage/handleBlobStorageIntegrationProjectJob.ts
@@ -323,6 +323,8 @@ const processBlobStorageExport = async (config: {
maxConcurrentParts: number | undefined;
maxPartAttempts: number | undefined;
skipEnrichment: boolean;
+ // ClickHouse send_timeout (seconds) for the export query; undefined => CH default.
+ chSendTimeout: number | undefined;
bullmqJobId: string | undefined;
bullmqAttemptsMade: number;
}) => {
@@ -387,6 +389,9 @@ const processBlobStorageExport = async (config: {
config.maxPartAttempts,
);
}
+ if (config.chSendTimeout !== undefined) {
+ span.setAttribute("blob.config.chSendTimeout", config.chSendTimeout);
+ }
span.setAttribute("blob.config.skipEnrichment", config.skipEnrichment);
span.setAttribute("blob.config.rawPassthrough", config.rawPassthrough);
@@ -543,6 +548,7 @@ const processBlobStorageExport = async (config: {
config.projectId,
config.minTimestamp,
config.maxTimestamp,
+ config.chSendTimeout,
)
).stream;
break;
@@ -552,6 +558,7 @@ const processBlobStorageExport = async (config: {
config.projectId,
config.minTimestamp,
config.maxTimestamp,
+ config.chSendTimeout,
)
).stream;
break;
@@ -562,6 +569,7 @@ const processBlobStorageExport = async (config: {
config.minTimestamp,
config.maxTimestamp,
exportFieldGroups,
+ config.chSendTimeout,
)
).stream;
break;
@@ -573,6 +581,7 @@ const processBlobStorageExport = async (config: {
config.maxTimestamp,
exportFieldGroups,
config.convertV4LatencyToSeconds,
+ config.chSendTimeout,
)
).stream;
break;
@@ -599,6 +608,7 @@ const processBlobStorageExport = async (config: {
config.minTimestamp,
config.maxTimestamp,
exportFieldGroups,
+ config.chSendTimeout,
)
: getEventsForBlobStorageExportRaw(
config.projectId,
@@ -606,6 +616,7 @@ const processBlobStorageExport = async (config: {
config.maxTimestamp,
exportFieldGroups,
config.convertV4LatencyToSeconds,
+ config.chSendTimeout,
);
const dataStream = countedStream(rawRows, sourceStats);
@@ -636,6 +647,7 @@ const processBlobStorageExport = async (config: {
config.projectId,
config.minTimestamp,
config.maxTimestamp,
+ config.chSendTimeout,
);
break;
case "observations":
@@ -647,6 +659,7 @@ const processBlobStorageExport = async (config: {
config.minTimestamp,
config.maxTimestamp,
exportFieldGroups,
+ config.chSendTimeout,
),
chStats,
),
@@ -662,6 +675,7 @@ const processBlobStorageExport = async (config: {
config.projectId,
config.minTimestamp,
config.maxTimestamp,
+ config.chSendTimeout,
);
break;
case "observations_v2": // observations_v2 is the events table
@@ -673,6 +687,7 @@ const processBlobStorageExport = async (config: {
config.minTimestamp,
config.maxTimestamp,
exportFieldGroups,
+ config.chSendTimeout,
),
chStats,
),
@@ -1152,6 +1167,7 @@ export const handleBlobStorageIntegrationProjectJob = async (
maxConcurrentParts: exportTuning.maxConcurrentParts,
maxPartAttempts: exportTuning.maxPartAttempts,
skipEnrichment: exportTuning.skipEnrichment,
+ chSendTimeout: exportTuning.chSendTimeout,
bullmqJobId: job.id,
bullmqAttemptsMade: job.attemptsMade,
};