- Add per-collection row cap (default 10k, env EXPORT_ROW_CAP) via Prisma take on all findMany calls - Add total size cap (default 100MB, env EXPORT_SIZE_CAP_MB); throws PayloadTooLargeException (413) when exceeded - Convert response to Node.js Readable stream piped via NestJS StreamableFile to avoid large in-memory buffers - Export ExportUserDataResult interface (stream + truncated flag) from handler - Update controller to set Content-Type/Content-Disposition headers and return StreamableFile - Document EXPORT_ROW_CAP and EXPORT_SIZE_CAP_MB env vars in Swagger - Extend tests: row-cap assertion (take arg), size-cap 413 path, stream assertions Fixes GOO-223 (M-1 from GOO-200 audit). Co-Authored-By: Paperclip <noreply@paperclip.ing>
20 lines
410 B
JSON
20 lines
410 B
JSON
{
|
|
"name": "@goodgo/contracts-events",
|
|
"version": "0.1.0",
|
|
"private": true,
|
|
"main": "./src/index.ts",
|
|
"types": "./src/index.ts",
|
|
"exports": {
|
|
".": "./src/index.ts",
|
|
"./schemas/*": "./schemas/*"
|
|
},
|
|
"scripts": {
|
|
"lint": "echo \"(no lint configured)\"",
|
|
"typecheck": "tsc --noEmit",
|
|
"test": "echo \"(no tests yet)\""
|
|
},
|
|
"devDependencies": {
|
|
"typescript": "^5.5.0"
|
|
}
|
|
}
|