| From: | Paul A Jungwirth <pj(at)illuminatedcomputing(dot)com> |
|---|---|
| To: | Zhijie Hou <houzhijie22(at)gmail(dot)com> |
| Cc: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, kedar anavardekar <kedar(dot)anavardekar(at)gmail(dot)com>, Nisha Moond <nisha(dot)moond412(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Andres Freund <andres(at)anarazel(dot)de>, Peter Eisentraut <peter(at)eisentraut(dot)org> |
| Subject: | Re: Fix WITHOUT OVERLAPS multirange with location replication |
| Date: | 2026-10-13 00:07:29 |
| Message-ID: | CA+renyVWtmNuc869cr8f2d1u-=kwEMF=qJw1LHQvMy22M-7ccg@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Mon, Oct 12, 2026 at 7:50 AM Zhijie Hou <houzhijie22(at)gmail(dot)com> wrote:
>
> Agreed. We can fix the reported issue for now. I'm attaching a merged patch
> that uses the index comparison approach to fix only the reported issue here. I
> also improved the test for the update_deleted detection code path to hold
> slot.xmin stable, and removed some unnecessary instance creation/deletion to
> make it lighter. Please see the updated patch.
This v4 looks good to me. Thank you for helping with this! Maybe one
minor change:
src/test/subscription/t/035_conflicts.pl
+# Publisher table holding the row that will be updated.
+$node_B->safe_psql(
+ 'postgres', "
+ CREATE TABLE tab_mr (id int4multirange, valid_at daterange, v int);
+ ALTER TABLE tab_mr REPLICA IDENTITY FULL;
+ INSERT INTO tab_mr VALUES ('{[1,5)}', '[2000-01-01,2010-01-01)', 1);
+ ALTER PUBLICATION tap_pub_B ADD TABLE tab_mr;
+");
If we say PRIMARY KEY (id, valid_at WITHOUT OVERLAPS) then we don't
need REPLICA IDENTITY FULL.
Yours,
--
Paul ~{:-)
pj(at)illuminatedcomputing(dot)com
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Greg Burd | 2026-10-13 00:27:55 | Re: UNDO with FILEOPS, and the FLUX table AM |
| Previous Message | Bharath Rupireddy | 2026-10-13 00:01:08 | Re: Use WALReadFromBuffers in more places |