Re: Logical Replication Custom Column Expression - Mailing list pgsql-hackers

From Stavros Koureas
Subject Re: Logical Replication Custom Column Expression
Date
Msg-id CA+O1jk4qsW5yOXCjgut7sT6SZn-frbobbakUSSp7i1iKa5a1FQ@mail.gmail.com
Whole thread Raw
In response to Re: Logical Replication Custom Column Expression  (Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>)
Responses Re: Logical Replication Custom Column Expression
Re: Logical Replication Custom Column Expression
List pgsql-hackers


Στις Τρί 29 Νοε 2022 στις 3:27 μ.μ., ο/η Ashutosh Bapat <ashutosh.bapat.oss@gmail.com> έγραψε:
> That would be too restrictive - not necessarily in your application
> but generally. There could be some tables where consolidating rows
> with same PK from different publishers into a single row in subscriber
> would be desirable. I think we need to enable the property for every
> subscriber that intends to add publisher column to the desired and
> subscribed tables. But there should be another option per table which
> will indicate that receiver should add publisher when INSERTING row to
> that table.

So we are discussing the scope level of this property, if this property will be implemented on subscriber level or on subscriber table.
In that case I am not sure how this will be implemented as currently postgres subscribers can have multiple tables streamed from a single publisher.
In that case we may have an additional syntax on subscriber, for example:

CREATE SUBSCRIPTION sub1 CONNECTION 'host=localhost port=5432 user=postgres password=XXXXXX dbname=publisher1' PUBLICATION pub1 with (enabled = false, create_slot = false, slot_name = NONE, tables = {tableA:union, tableB:none, ....});

Something like this?

> And yes, probably you need to change the way you reply to email on
> this list. Top-posting is generally avoided. See
https://wiki.postgresql.org/wiki/Mailing_Lists.

Thanks for bringing this into the discussion :)

pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: ExecRTCheckPerms() and many prunable partitions
Next
From: Masahiko Sawada
Date:
Subject: Re: [PoC] Improve dead tuple storage for lazy vacuum