Hasty Briefsbeta

Bilingual

Show HN: 100% open source, logical multi-master PostgreSQL replication

6 months ago
  • #PostgreSQL
  • #Spock Extension
  • #Database Replication
  • Spock extension provides multi-master replication for PostgreSQL versions 15 and later.
  • Each node in the cluster must have the Spock extension installed.
  • Tables must have the same name, schema, columns, and primary keys across all nodes.
  • PostgreSQL source tree must be patched with version-specific .diff files before building Spock.
  • Postgres server must be configured with specific settings like `wal_level = 'logical'` and `shared_preload_libraries = 'spock'`.
  • Spock documentation is built using MkDocs with the Material theme.
  • Replication cluster configuration involves modifying `postgresql.conf` and `pg_hba.conf` files.
  • Nodes are created using `spock.node_create` and subscriptions are established with `spock.sub_create`.
  • Automatic DDL replication can be enabled with `spock.enable_ddl_replication=on`.
  • Upgrading Spock requires a backup as rollback is not possible due to catalog table changes.