Settings

Theme

Show HN: SyncLite – An embedded synchronization layer for SQLite and DuckDB

github.com

2 points by mahcha · 4 comments · 1 min read

Reader

Hi HN,

We have been building SyncLite, an open-source platform to simplify offline-first application development.

If your application uses SQLite or DuckDB, SyncLite lets it continue using the local database as usual while synchronization happens in the background.

For SQL-based applications, SyncLite records transactions into transactionally consistent .sqlog files using SQLite as an open replication format. A background consolidator replays those transactions, derives row-level CDC and schema changes, and applies them transactionally to destination databases like PostgreSQL.

The same architecture supports both database replication and many-to-one data consolidation. For applications that don't work directly with SQL, SyncLite also provides Store Devices (CRUD APIs) and Streaming Devices.

SyncLite is open source and available for Java, Python, Rust, and native C/C++ ( nodejs, .NET, go in roadmap).

GitHub: https://github.com/syncliteio/SyncLite

We wouldd love your feedback on the architecture, developer experience, and whether this is something you would find useful for building offline-first applications.

1 thread
askmenot26

Interesting ! Quite often repl projects like this provide no or half baked support for schema change sync.. Does this handle schema changes seamlessly?

  • mahchaOP

    Each write operation (DDL + DML) is transactionally captured by the synclite logger ( a wrapper over underlying embedded db) and logged into the log file. So, it handles all schema operations create, drop, alter ( add/drop/rename column), rename column/table, in addition to the dml operations insert/update/delete.

    • askmenot26

      how does it handle changes done on destination database? Does it sync them back to local database ?

      • mahchaOP

        SyncLite currently supports unidirectional replication/consolidation from embedded database to destination database. Reverse path from destination to local db(with conflict resolution) is on the roadmap.

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection