One edge case not addressed in the README is the use of DEFAULT on ALTER TABLE ... ADD COLUMN with a volatile function.
For example, if you run this statement on the publisher
ALTER TABLE tab ADD COLUMN col timestamp DEFAULT CURRENT_TIMESTAMP;
then the subscriber will (probably) populate the new column with a different value.
There are simple workarounds in this case (although they are less efficient on the publisher), and I understand that there may be no way to solve this without changes in core postgres, but I think this should result in either an error or a warning from the extension.
For comparison, EDB's PGD has support DDL replication, in with their implementation if you tried my example above you would get the error
ERROR: ALTER TABLE ... ADD COLUMN ... (mutable) DEFAULT may not affect replicated tables on a BDR node
CONTEXT: "xact rep": true, "ddl rep": true, "ddl locking": all
One edge case not addressed in the README is the use of
DEFAULTonALTER TABLE ... ADD COLUMNwith a volatile function.For example, if you run this statement on the publisher
then the subscriber will (probably) populate the new column with a different value.
There are simple workarounds in this case (although they are less efficient on the publisher), and I understand that there may be no way to solve this without changes in core postgres, but I think this should result in either an error or a warning from the extension.
For comparison, EDB's PGD has support DDL replication, in with their implementation if you tried my example above you would get the error