RE: wake up logical workers after ALTER SUBSCRIPTION - Mailing list pgsql-hackers

From houzj.fnst@fujitsu.com
Subject RE: wake up logical workers after ALTER SUBSCRIPTION
Date
Msg-id OS0PR01MB5716860B1454C34E5B179B6694C99@OS0PR01MB5716.jpnprd01.prod.outlook.com
Whole thread Raw
In response to Re: wake up logical workers after ALTER SUBSCRIPTION  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: wake up logical workers after ALTER SUBSCRIPTION
List pgsql-hackers
On Monday, January 23, 2023 3:13 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:

Hi,

>
> Nathan Bossart <nathandbossart@gmail.com> writes:
> > On Tue, Jan 10, 2023 at 10:59:14AM +0530, Amit Kapila wrote:
> >> I haven't looked in detail but isn't it better to explain somewhere
> >> in the comments that it achieves to rate limit the restart of workers
> >> in case of error and allows them to restart immediately in case of
> >> subscription parameter change?
>
> > I expanded one of the existing comments to make this clear.
>
> I pushed v17 with some mostly-cosmetic changes, including more comments.

I noticed one minor thing in this commit.

-
LogicalRepCtx->last_start_dsh = DSM_HANDLE_INVALID;
-

The code takes the last_start_dsh as dsm_handle, but it seems it is a dsa_pointer.
" typedef dsa_pointer dshash_table_handle;" This won’t cause any problem, but I feel
It would be easier to understand if we take it as dsa_pointer and use InvalidDsaPointer here,
like what he attached patch does. What do you think ?

Best regards,
Hou zj




Attachment

pgsql-hackers by date:

Previous
From: Kyotaro Horiguchi
Date:
Subject: Re: Time delayed LR (WAS Re: logical replication restrictions)
Next
From: Andres Freund
Date:
Subject: Re: Decoupling antiwraparound autovacuum from special rules around auto cancellation