/** * Worker thread for parallel Parquet generation. * * A row group's BYTES do not depend on where it sits in the file: page headers * carry sizes, and the only offsets in the format live in the footer. So a * worker can build whole groups on its own and hand back both the bytes and * the metadata, leaving the coordinator to concatenate and fix the offsets. * * The split is by GROUP, never by an arbitrary row count. Cutting mid-group * would produce groups a single-threaded run never makes, and the two outputs * would stop matching — which is the property `--jobs` is supposed to preserve. */ import type { ChunkMeta } from '../output/parquet/writer.js'; export interface ParquetWorkerInput { readonly source: string; readonly seed: string; readonly count: number; /** An override the caller asked for; `undefined` leaves the config's own `local=` alone. */ readonly locale?: string | undefined; /** The project config's locale — a fallback, never an override. */ readonly defaultLocale?: string | undefined; readonly now: number; readonly dataPaths?: readonly string[] | undefined; readonly baseDir?: string | undefined; /** Row-group indices `[startGroup, endGroup)` this worker owns. */ readonly startGroup: number; readonly endGroup: number; readonly tmpPath: string; } /** What the coordinator needs to place this worker's output and describe it. */ export interface ParquetWorkerGroup { readonly chunks: ChunkMeta[]; readonly numRows: number; readonly byteLength: number; } export interface ParquetWorkerResult { readonly ok: true; readonly groups: ParquetWorkerGroup[]; /** Total bytes written to the temp file. */ readonly byteLength: number; } //# sourceMappingURL=parquet-worker.d.ts.map