Re: Proposal: Conflict log history table for Logical Replication

From: Zhijie Hou <houzhijie22(at)gmail(dot)com>
To: Peter Smith <smithpb2250(at)gmail(dot)com>
Cc: vignesh C <vignesh21(at)gmail(dot)com>, Nisha Moond <nisha(dot)moond412(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, shveta malik <shveta(dot)malik(at)gmail(dot)com>, shihao zhong <zhong950419(at)gmail(dot)com>, Dilip Kumar <dilipbalaut(at)gmail(dot)com>, saurabh singh <saurabh(dot)singh214(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, shveta malik <shvetamalik(at)gmail(dot)com>
Subject: Re: Proposal: Conflict log history table for Logical Replication
Date: 2026-11-24 07:46:43
Message-ID: 1257417f-cc58-4039-b8a9-498ff361ebf1@gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

On Tue, Nov24, 2026 at 09:31 AM Peter Smith wrote:
> Some review comments for docs in patch v96-0001.
>
> ======
> doc/src/sgml/logical-replication.sgml
>
> 1
> + <literal>delete_missing</literal>). In these cases, local data may diverge
> + or be overwritten, making a queryable audit log valuable for DBAs to
> + understand why a row changed or was skipped.
>
> It is rare to say "DBAs" in the docs. Mostly PostgreSQL docs refer to
> "database administrators".

Changed.

>
> ~~~
>
> 2.
> + <para>
> + Every value in <literal>replica_identity</literal> is written as a
> + <acronym>JSON</acronym> string. For most columns, this is the same text a
> + <command>SELECT</command> of that column would show. Values are quoted
> + whatever the column's type, so numbers, booleans and <type>jsonb</type>
> + documents all appear as strings:
>
> It seems redundant to say "Values are quoted..."?
>
> The first sentence already said, "Every value in
> <literal>replica_identity</literal> is written as a
> <acronym>JSON</acronym> string".

I prefer keeping this sentence as it looks clearer and introduces the
example below.

>
> ~~~
>
> 3.
> + Large values are dropped rather than shortened, because a shortened value
> + would still look like a real one and would give wrong answers when
> + compared or joined against the table.
>
> IMO, slightly different wording would be better:
> - "are omitted" instead of "are dropped".
> - "truncated" instead of "shortened"
>
> ~~~
>
> 4.
...
>
> 5.
...

Points 3, 4, and 5 look good to me; addressed in v97.

Here is the v97 patch set (only 0001 is changed, along with minor commit
message and comment polish).

--
Best Regards,
Zhijie Hou

Attachment Content-Type Size
v97-0001-Record-logical-replication-conflicts-in-the-conf.patch text/plain 133.8 KB
v97-0002-Preserve-conflict-log-destination-and-subscripti.patch text/plain 25.9 KB
v97-0003-Add-conflict-log-table-information-to-describe-s.patch text/plain 80.3 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Zhijie Hou 2026-11-24 07:48:33 Re: Proposal: Conflict log history table for Logical Replication
Previous Message David Geier 2026-11-24 07:45:44 Re: Use local buffer for packed numerics