RE: Data is copied twice when specifying both child and parent table in publication

From: "wangw(dot)fnst(at)fujitsu(dot)com" <wangw(dot)fnst(at)fujitsu(dot)com>
To: Peter Smith <smithpb2250(at)gmail(dot)com>
Cc: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, "osumi(dot)takamichi(at)fujitsu(dot)com" <osumi(dot)takamichi(at)fujitsu(dot)com>, "shiy(dot)fnst(at)fujitsu(dot)com" <shiy(dot)fnst(at)fujitsu(dot)com>, "houzj(dot)fnst(at)fujitsu(dot)com" <houzj(dot)fnst(at)fujitsu(dot)com>, Amit Langote <amitlangote09(at)gmail(dot)com>, Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Dilip Kumar <dilipbalaut(at)gmail(dot)com>, Greg Nancarrow <gregn4422(at)gmail(dot)com>, vignesh C <vignesh21(at)gmail(dot)com>
Subject: RE: Data is copied twice when specifying both child and parent table in publication
Date: 2022-09-20 06:17:48
Message-ID: OS3PR01MB6275B4F7F5F5CF3A1A76D0FB9E4C9@OS3PR01MB6275.jpnprd01.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Sept 19, 2022 at 14:52 PM Peter Smith <smithpb2250(at)gmail(dot)com> wrote:
> FYI, I'm not sure why the cfbot hasn't reported this, but the apply v9
> patch failed for me on HEAD as below:
>
> [postgres(at)CentOS7-x64 oss_postgres_misc]$ git apply
> ../patches_misc/HEAD_v9-0001-Fix-data-replicated-twice-when-specifying-
> publish.patch
> --verbose
> Checking patch src/backend/catalog/pg_publication.c...
> Checking patch src/backend/commands/subscriptioncmds.c...
> Hunk #1 succeeded at 1917 (offset 123 lines).
> Checking patch src/include/catalog/pg_proc.dat...
> Hunk #1 succeeded at 11607 (offset -74 lines).
> Checking patch src/test/regress/expected/rules.out...
> error: while searching for:
> JOIN pg_attribute a ON (((a.attrelid = gpt.relid) AND
> (a.attnum = k.k))))) AS attnames,
> pg_get_expr(gpt.qual, gpt.relid) AS rowfilter
> FROM pg_publication p,
> LATERAL pg_get_publication_tables((p.pubname)::text) gpt(relid,
> attrs, qual),
> (pg_class c
> JOIN pg_namespace n ON ((n.oid = c.relnamespace)))
> WHERE (c.oid = gpt.relid);
>
> error: patch failed: src/test/regress/expected/rules.out:1449
> error: src/test/regress/expected/rules.out: patch does not apply
> Checking patch src/test/subscription/t/013_partition.pl...
> Checking patch src/test/subscription/t/028_row_filter.pl...
> Checking patch src/test/subscription/t/031_column_list.pl...

Thanks for your kindly reminder.

Rebased the patch based on the changes in HEAD (20b6847).
Attach the new patches.

Regards,
Wang wei

Attachment Content-Type Size
HEAD_v10-0001-Fix-data-replicated-twice-when-specifying-publis.patch application/octet-stream 18.7 KB
REL15_v10-0001-Fix-data-replicated-twice-when-specifying-publis_patch application/octet-stream 8.4 KB
REL14_v10-0001-Fix-data-replicated-twice-when-specifying-publis_patch application/octet-stream 5.3 KB
REL13_v10-0001-Fix-data-replicated-twice-when-specifying-publis_patch application/octet-stream 5.3 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Munro 2022-09-20 06:35:51 Re: Proposal to use JSON for Postgres Parser format
Previous Message bt22nakamorit 2022-09-20 06:15:39 Re: Make ON_ERROR_STOP stop on shell script failure