Syncle

Keep multiple databases in sync without kafka

Syncle connects to PostgreSQL, MySQL, SQLite, MongoDB and Redis. You pick a table on one of them and where it should go on another. Syncle copies the rows across, then keeps copying as the source changes.

curl -fsSL https://syncle.dev/install | sh -s -- up

Docker with Compose v2 is all you need. Runs on your own machine, MIT licensed.

What it does

PostgreSQLSyncleMySQLMongoDBRedis
One Postgres table feeding three other databases at the same time.

A bridge connects one source to one or more destinations. Any engine can sit on either side, so a Postgres table can go to MongoDB, to Redis, or to another Postgres. A destination can also be an HTTP endpoint, if you are feeding a service instead of a database.

If the destination table does not exist yet, Syncle creates it and works out the column types for that engine. Writes are upserts, so running a sync twice will not leave you with two copies of a row. A job that dies partway through restarts from the last row it recorded, not from the beginning.

Three ways to run a bridge

Two things to know. SQLite has no change log, so watch is the only option there. Redis keyspace notifications are not durable, so a Redis CDC bridge misses anything that changes while Syncle is off. Both are covered in how bridges work and CDC setup.

Installing

  1. Run the command above. It checks for Docker, pulls the image, starts four containers and opens localhost:3002.
  2. Create your account. The setup form opens with a one-time token already in it.
  3. Build a bridge. Choose a source table, choose a destination, press start.

After that you use the launcher:

The script is install.sh if you want to read it before you run it. The installation page covers the manual Docker Compose route.

Documentation

Questions and bugs

Setup questions go in Discussions. Bugs go in the issue tracker, including anywhere the docs and the software disagree. For a security problem, email instead of opening an issue.