Re: [19] CREATE SUBSCRIPTION ... SERVER - Mailing list pgsql-hackers

From Jeff Davis
Subject Re: [19] CREATE SUBSCRIPTION ... SERVER
Date
Msg-id 25e841738fba648755cb3882327f4744f4c8cfe9.camel@j-davis.com
Whole thread Raw
In response to Re: [19] CREATE SUBSCRIPTION ... SERVER  (Amit Kapila <amit.kapila16@gmail.com>)
Responses Re: [19] CREATE SUBSCRIPTION ... SERVER
List pgsql-hackers
On Mon, 2026-03-16 at 11:08 +0530, Amit Kapila wrote:
> Won't it be sufficient if we just reset MySubscriptionCtx here or in
> callback subscription_change_cb()?

The old and new subscriptions are compared against eachother (to see
whether to restart the worker or not), so they both have to exist at
the same time. If we put them in the same context, then we can't reset
it.

I suppose we could have just two contexts and switch back and forth
between them, resetting the last one. But that doesn't seem to be worth
the trouble.

Regards,
    Jeff Davis




pgsql-hackers by date:

Previous
From: "Greg Burd"
Date:
Subject: Re: Expanding HOT updates for expression and partial indexes
Next
From: Ashutosh Bapat
Date:
Subject: Re: SQL Property Graph Queries (SQL/PGQ)