Skip to content

feat: implement background R2 streaming dumps and fix RLS table matching issues#275

Open
singhaditya21 wants to merge 2 commits into
outerbase:mainfrom
singhaditya21:feat-streaming-exports
Open

feat: implement background R2 streaming dumps and fix RLS table matching issues#275
singhaditya21 wants to merge 2 commits into
outerbase:mainfrom
singhaditya21:feat-streaming-exports

Conversation

@singhaditya21

@singhaditya21 singhaditya21 commented Jun 13, 2026

Copy link
Copy Markdown

Closes #59
/claim #59

This PR implements a memory-efficient keyset-based paging and streaming mechanism for database dumps, supporting direct streaming downloads and async background uploads to Cloudflare R2.

Demo Video:

https://github.com/singhaditya21/starbasedb/raw/feat-streaming-exports/tests/assets/streaming_exports_demo.webm

Features

  1. Keyset-based paging using SQLite _rowid_ to avoid offset degradation.
  2. Backpressure-aware streaming (ReadableStream) that yields event loop execution using breathing intervals.
  3. R2 Multipart Upload integration for background exports with chunked buffer flush (min 5 MiB R2 limit).
  4. Row Level Security subqueries support and base table normalization.

@singhaditya21

Copy link
Copy Markdown
Author

Hi! This PR is ready for review and verified to pass all tests locally. Could you please click 'Approve and run' to trigger the automated CI workflows? Thanks!

@singhaditya21

Copy link
Copy Markdown
Author

Hi maintainers! Just checking in on this background R2 streaming dumps PR (#59). It passes all tests locally. Could you please approve running the workflow actions on forks to trigger the CI checks? Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Database dumps do not work on large databases

1 participant