RFC: logical publication via inheritance root?

From: Jacob Champion <jchampion(at)timescale(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: RFC: logical publication via inheritance root?
Date: 2022-12-09 18:21:21
Message-ID: CAAWbhmiRRJDzbA4fv0vAViu_wfoeYqtT+VYOOu7845WO-yT35w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

TImescale makes use of inheritance in its partitioning implementation,
so we can't make use of the publish_via_partition_root publication
option during logical replication. We don't guarantee that the exact
same partitions exist on both sides, so that's a major roadblock for
our implementing logical subscription support, and by the same token
it's not possible to replicate out to a "standard" table.

If we were to work on a corresponding publish_via_inheritance_root
option, is there a chance that it'd be accepted, or is there some
other technical reason preventing it? In addition to Timescale, it
seems like other installations using extensions like pg_partman could
potentially make use of this, during online migrations from the old
style of partitioning to the new.

Some inheritance hierarchies won't be "partitioned" hierarchies, of
course, but the user can simply not set that replication option for
those publications. (Alternatively, I can imagine a system where an
extension explicitly marks a table as having a different "publication
root", and then handling that marker with the existing replication
option. But that may be overengineering things.)

WDYT?

--Jacob

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Mark Dilger 2022-12-09 18:39:22 Re: [PATCH] random_normal function
Previous Message samay sharma 2022-12-09 18:10:21 Re: PGDOCS - Logical replication GUCs - added some xrefs