Re: Proposal: Conflict log history table for Logical Replication
Dilip Kumar <dilipbalaut@gmail.com>
From: Dilip Kumar <dilipbalaut@gmail.com>
To: Amit Kapila <amit.kapila16@gmail.com>
Cc: vignesh C <vignesh21@gmail.com>, Nisha Moond <nisha.moond412@gmail.com>, shveta malik <shveta.malik@gmail.com>, Peter Smith <smithpb2250@gmail.com>, Masahiko Sawada <sawada.mshk@gmail.com>, Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2026-06-25T13:45:02Z
Lists: pgsql-hackers
Attachments
- v58-0002-Report-error-for-ddls-on-conflict-log-tables.patch (application/octet-stream) patch v58-0002
- v58-0003-Implement-the-conflict-insertion-infrastructure-.patch (application/octet-stream) patch v58-0003
- v58-0001-Add-configurable-conflict-log-table-for-Logical-.patch (application/octet-stream) patch v58-0001
- v58-0004-Preserve-conflict-log-destination-and-subscripti.patch (application/octet-stream) patch v58-0004
- v58-0005-Add-conflict-log-table-information-to-describe-s.patch (application/octet-stream) patch v58-0005
- v58-0006-Documentation-patch.patch (application/octet-stream) patch v58-0006
On Thu, Jun 25, 2026 at 6:37 PM Amit Kapila <amit.kapila16@gmail.com> wrote: > > On Thu, Jun 25, 2026 at 6:30 PM Dilip Kumar <dilipbalaut@gmail.com> wrote: > > > > On Thu, Jun 25, 2026 at 4:57 PM Amit Kapila <amit.kapila16@gmail.com> wrote: > > > > > > > > 2. > > > @@ -2482,6 +2681,8 @@ DropSubscription(DropSubscriptionStmt *stmt, > > > bool isTopLevel) > > > deleteDependencyRecordsFor(SubscriptionRelationId, subid, false); > > > deleteSharedDependencyRecordsFor(SubscriptionRelationId, subid, 0); > > > > > > + drop_sub_conflict_log_table(subid, subname, subconflictlogrelid); > > > > > > It would be better to drop the table before cleaning up the dependency > > > record. Right now, it is okay even in current order because dependency > > > removal is trying to remove where subid is depender. > > > > So whats your suggestion change it now or not? I feel either way is fine. > > > > Let's change now itself. PFA, updated version of the patch, fixes all the comments of V57 Open comments 1. Need more thought on converting to JSONB column 2. Shveta's comments on saving the results of the common query is not yet fixed, I will put more thought on this. -- Regards, Dilip Kumar Google
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Allow logical replication conflicts to be logged to a table.
- a5918fddf10d master landed
-
Avoid orphaned objects dependencies
- 2fbb21170e90 19 (unreleased) cited