RE: Handle infinite recursion in logical replication setup

From: "kuroda(dot)hayato(at)fujitsu(dot)com" <kuroda(dot)hayato(at)fujitsu(dot)com>
To: 'Peter Smith' <smithpb2250(at)gmail(dot)com>
Cc: Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, vignesh C <vignesh21(at)gmail(dot)com>
Subject: RE: Handle infinite recursion in logical replication setup
Date: 2022-04-07 06:03:34
Message-ID: TYAPR01MB5866A1CCE4F5B176DE98E565F5E69@TYAPR01MB5866.jpnprd01.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Dear Peter,

> FYI, here is a test script that is using the current patch (v6) to
> demonstrate a way to share table data between different numbers of
> nodes (up to 5 of them here).

Thanks for sharing your script! It's very helpful for us.

While reading your script, however, I had a question about it.
Line 121-122, you defined subscriptions for 2-nodes cluster:

psql -p $port_N1 -c "create subscription sub12 connection 'port=$port_N2' publication pub2 with ($copy_force);"
psql -p $port_N2 -c "create subscription sub21 connection 'port=$port_N1' publication pub1 with ($copy_force);"

But I was not sure it works well.
N2 already have shared data from N1 when subscription sub21 is created.
Did you assume that the initial copying is not so quick and
data synchronization will be not done when creating sub21?

Best Regards,
Hayato Kuroda
FUJITSU LIMITED

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Smith 2022-04-07 06:13:56 Re: Handle infinite recursion in logical replication setup
Previous Message Michael Paquier 2022-04-07 05:53:22 Re: Supply restore_command to pg_rewind via CLI argument