cr-sqlite icon indicating copy to clipboard operation
cr-sqlite copied to clipboard

Enable query based replication

Open tantaman opened this issue 2 years ago • 3 comments

Most use cases would likely rather replicate a subset of the database as specified by a query rather than all changes occurring on the database.

Query based replication would replicate only the changes that match some query or set of queries.

tantaman avatar Nov 17 '22 19:11 tantaman

If we extend https://github.com/vlcn-io/cr-sqlite/issues/195 to also do efficient primary key and table filtering, this will get us 50% of the way there with little work.

tantaman avatar Apr 24 '23 17:04 tantaman

We're pretty close to enabling this with the recent additions of:

  • crsql_tracked_peers
  • & #195

tantaman avatar Apr 28 '23 16:04 tantaman

Looks like we could do this via https://doc.replicache.dev/strategies/row-version

as I've explored here: https://github.com/tantaman/repliear-row-versioning

tantaman avatar Nov 21 '23 19:11 tantaman