Skip to content

feat: streaming JSON-Lines ledger export - #642

Merged
thlpkee20-wq merged 3 commits into
RevoraOrg:masterfrom
Godfrey-Delight:feat/ledger-export-stream-jsonl
Jul 29, 2026
Merged

feat: streaming JSON-Lines ledger export#642
thlpkee20-wq merged 3 commits into
RevoraOrg:masterfrom
Godfrey-Delight:feat/ledger-export-stream-jsonl

Conversation

@Godfrey-Delight

Copy link
Copy Markdown
Contributor

Adds a streaming GET /ledger/export.jsonl route in ledgerRoutes.ts that emits canonical ledger entries in chunked JSON-Lines format, opening with a single-line manifest (params + estimated row count via a fast COUNT(*) query), injecting a # keepalive comment every 100 rows to keep proxies from dropping the socket, and using pg-cursor in batches of 100 for back-pressure with a _destroy handler that releases the DB client and cursor on early disconnect; emits export.stream.rows and export.stream.duration telemetry.
Closes #483

Adds a streaming GET /ledger/export.jsonl route in ledgerRoutes.ts that emits canonical ledger entries in chunked JSON-Lines format, opening with a single-line manifest (params + estimated row count via a fast COUNT(*) query), injecting a # keepalive comment every 100 rows to keep proxies from dropping the socket, and using pg-cursor in batches of 100 for back-pressure with a _destroy handler that releases the DB client and cursor on early disconnect; emits export.stream.rows and export.stream.duration telemetry.

Closes RevoraOrg#483
@drips-wave

drips-wave Bot commented Jul 29, 2026

Copy link
Copy Markdown

@Godfrey-Delight Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Godfrey-Delight
Godfrey-Delight force-pushed the feat/ledger-export-stream-jsonl branch from c8ad51c to 88303f4 Compare July 29, 2026 00:52
@thlpkee20-wq
thlpkee20-wq merged commit 35b4290 into RevoraOrg:master Jul 29, 2026
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add ledger-export streaming endpoint with chunked JSON-Lines for large exports

2 participants