Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wfEGz-005LMD-1a for pgsql-hackers@arkaria.postgresql.org; Thu, 02 Jul 2026 10:03:57 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wfEGy-001Ifc-1J for pgsql-hackers@arkaria.postgresql.org; Thu, 02 Jul 2026 10:03:56 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wfEGy-001IfS-0A for pgsql-hackers@lists.postgresql.org; Thu, 02 Jul 2026 10:03:56 +0000 Received: from mail-pg1-x531.google.com ([2607:f8b0:4864:20::531]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wfEGv-00000001MJP-2Ler for pgsql-hackers@lists.postgresql.org; Thu, 02 Jul 2026 10:03:55 +0000 Received: by mail-pg1-x531.google.com with SMTP id 41be03b00d2f7-c9aea40d799so747027a12.0 for ; Thu, 02 Jul 2026 03:03:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1782986631; cv=none; d=google.com; s=arc-20260327; b=T5qSjX1cQmImQpKPb1NZ0b/Yi7ZosqjqmHZDqdMPgpQ/athsuQ4dnzA4oGOyGPVMxA 9vhTnDoy+/FEi/w7wpzqm1aSEa7BZK+2dnBijkwHuU8Ucey4BQpsCkuD2b24IzdcQcpu 8DD+QMCWtssbQwQ1/SHJ4RtG1pImVMGAFpEA8AhIC9W/QHF1cxhpyGOnY+J3GMD9L5Nk hoQWJX8kA//0AhEq5Dom/lhDbzwOU1aaSTNBv/RgyRaDkLPWApY/du7vzLZT1KwsFuvZ T2MQ2VOWMwQrcqY1NcIg3Cv/2wtIpGa6a1R7AeA1+4y0oncv33m8LGPgcsdpmMQWhANx BYBQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=h7JmPrS2eR0PufPBgXayopOkuMpY1RxIBLOYywCpaXs=; fh=E2wr7L6PoARBy7e8G1PEg/PYuq+jLvnhG163sRM4QT0=; b=hT4NVyKDF7uz3y+qGTvHzj1a4T6QSEd9BQ5FChoHNyl5LAuNu6GRNxUX8UaUuZrRsl aNfNf1VAuL+AQOJH8xtZSWug8kMuYpwN6XW0Iyth35gMgnfkW15RJuT00grC6g0FViBH dk8r5TkpPgFK46axy7kp0a6HNPCu0seCqoZ2xR6N2FxVab+GNqwYoSwbMTuX0ErcVkHi uwoG2nVdy5XIxtoVaGx7P7qCAzY4B+7hSmbGtOrqs+AG5DgXhGwOM3TvzJI5njsG2sa0 8AgWnsp8esxCOqYOu5snqd2SNecWjQPyKPX5y7ph6Smodgtp88tPkc6ggj0Q8E8b6HCs QmZw==; darn=lists.postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1782986631; x=1783591431; darn=lists.postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=h7JmPrS2eR0PufPBgXayopOkuMpY1RxIBLOYywCpaXs=; b=g5L9lVHmdl6rP4HQhg7R1ZbsXk0B6fu062D9bDkNI0IrtF9vb/D4p44uhlgiTYnQ2o 8pyX42fRR4lVhe5IE6lTi67JYFlHJEXjpAZOF10eSCxlV5TKa4+Zf4sofiI9FrZjzZLe mz8EXpglmKJMh8rbS/2LZ+BPEBXzjfsC19NRD0izk2ol/qWpRwNHvA7n3BPxxXnwE7FM PVpdvgW7ngrjrBB5yodBbO03EK5zjOqRE3bAqa2kBNVH+dIMkB0Q0YbTNBHDR3NikLpG ESuV7qSzP8Z+qi+or1a4RgmPoRsCCEl74ZPOSrbFKlLCQTyynYRxJqlbMeqWZN6GdT4+ s8Ew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1782986631; x=1783591431; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=h7JmPrS2eR0PufPBgXayopOkuMpY1RxIBLOYywCpaXs=; b=SJ3hBq4hNMxnxjlK3wQMSRL3yM3cZQNMIKgsR5vP6aNbJcwEKxjyAfRc1+TxH+/QVq NJEMBvpyw0XZnJXeh6T4zYHtS0Qtu1e5zL6TQiPosz4z0w35F0WQ+8KFX+tgUdaGjyPa nOo/j+RaemCpt8rko4fA0QczSPgVUBFMC0yS+T2xZTHTtqMSJ0op35lO3zNPHZf4q6I1 SL8Al1g/iVUb1UHU/VwuC8exJzpNEUKXmrHcr60DxgVVLbq4cstFhZJ9o41IIYC1DRy7 eU5CIDuoLSz/6nz3gTn2XGN/azt2pHS0j306QFidx+9w1zjIymRzNrzwSCNKNo81Pfpp tSEQ== X-Forwarded-Encrypted: i=1; AFNElJ/5ffshFQYxbrtUr1jOVOMTgPjLNaUpT/dFSSqlzEh3+HP9IEONCenPvsUGut9Mt4sZM3DXcigGLMiiS6wn@lists.postgresql.org X-Gm-Message-State: AOJu0YzMdT6JEmwxl2bl/h7Dhw/mSezL3jChpsA5qrp0hmnll/EphJ4c RHuzRFFHxkPGdMYPN8agwNqaCTbsq+XdzujFiillF0A0Bw4GGZkbkWnBBFpTRaBkExZ10nIZiB4 YRQU2y1k/eHBT3CwXHdyZpujfSCoFDbc= X-Gm-Gg: AfdE7ck4uI3H1/gzGrSOwUpteLBsbp0iQx30/sdhjZccKbXBccl3iWyZXtzh2GbSLl5 UnFqz2flvY2iy9wLUAwd/+0o6EkHrg+0QrjhZWe5uPFOJD2A/tAXrL0fgXckt7xZ/H5DwbNm2/p NEO+yiFXhDkZ/NZlILOMaGJZMI59PglTWeM2w9M9Ty5VKXwDf0WAMiUUzL0Zde/TlQHHgchh3lS yQUOT6yP/GZrQdrllsKUlSYrSKVGvuSO+DF3Q3PtNrMQS8eAMgYcQmGA+XpVwOU0tv4PACYjp00 vLjpq6jfBC1HQGH3sHFbnPEAyGmNMNCHMLAMazqmhgN4Do9K74zuGpKXB5WWJbDBvXUS7R9GrvA = X-Received: by 2002:a05:6a21:6e84:b0:39b:dea7:5626 with SMTP id adf61e73a8af0-3bff4258cb4mr5509795637.35.1782986631163; Thu, 02 Jul 2026 03:03:51 -0700 (PDT) MIME-Version: 1.0 References: From: shveta malik Date: Thu, 2 Jul 2026 15:33:38 +0530 X-Gm-Features: AVVi8Cf4oKtZj_nouXXRdxY935ek5tzV5Xi86M8Qly0iWdCRfIH81niWtV8xUcQ Message-ID: Subject: Re: Proposal: Conflict log history table for Logical Replication To: Dilip Kumar Cc: Amit Kapila , Peter Smith , vignesh C , Nisha Moond , Masahiko Sawada , Bharath Rupireddy , PostgreSQL Hackers , shveta malik Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, Jul 2, 2026 at 1:39=E2=80=AFPM Dilip Kumar = wrote: > > > I rebased the remaining patches on top of HEAD. So far, I have run > pgindent and completed the doc merge for 0001. The 0002 and 0003 are > just rebased. > Thanks, a few trivial comments for 001: 1) logical-replication.sgml: + + Conflict logging + + Additional logging is triggered, and the conflict statistics are collected (displayed in the Starting new section with 'Additional' seems odd. we can simply say: Conflict logging is triggered, and conflict statistics are collected (displayed in the 2) IMO, to relate the 3 sections: '29.8.1. Conflict logging', '29.8.2. Table-based logging' and ' 29.8.3. File-based logging', we can add below line as well to 29.8.1, thus overall it will look like: Conflict logging is triggered, and conflict statistics are collected (displayed in the pg_stat_subscription_stats view) for the conflict cases described below. Depending on the value of conflict_log_destination, the conflict information is written to the server log, a conflict log table, or both. 3) create_subscription.sgml: + Records conflict details to both destinations log + and table. Either we can have: Records conflict details to both the server log and the conflict log table. OR Records conflict details to both destinations: the server log and the conflict log table 4) conflict.c: +#include "access/xact.h" +#include "utils/memutils.h" These are not needed. 5) build_local_conflicts_json_array: + json_datum =3D heap_copy_tuple_as_datum(tuple, tupdesc); + + /* + * Build the higher level JSON datum in format described in function + * header. + */ + json_datum =3D DirectFunctionCall1(row_to_json, json_datum); The first one is not json_datum, it is simply datum. Perhaps we shall change the varibale for first one to 'Datum datum' like we have at all other places in this file. thanks Shveta