Parent categories: Distributed data storage.

Synchronize Postgresql databases

Imagine issuing a COPY TO query for every table in a database and then syncing the resulting CSV with other nodes. We can add a version column to every table so we avoid syncing unnecessarily. Conflict detection could be implemented by showing multiple copied and marking one as active.

YAML Interest

I am thinking of writing some program to synchronize Postgres databases. I would issue a COPY TO command on every table with a version greater than column check and then transfer it to other nodes and the same happens in reverse. CSV has parsers in many languages so it could be written in any language. Conflicts can be resolved by having a policy where the winning version is marked active.


No child categories.


Vote (Optional) (suppress notifications) (Optional)
Please, log in.