Re: [19] CREATE SUBSCRIPTION ... SERVER

Amit Kapila <amit.kapila16@gmail.com>

From: Amit Kapila <amit.kapila16@gmail.com>
To: Álvaro Herrera <alvherre@kurilemu.de>
Cc: Jeff Davis <pgsql@j-davis.com>, Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>, Masahiko Sawada <sawada.mshk@gmail.com>, Shlok Kyal <shlok.kyal.oss@gmail.com>, Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>, Joe Conway <mail@joeconway.com>, "L. pgsql-hackers" <pgsql-hackers@postgresql.org>
Date: 2026-03-21T10:55:06Z
Lists: pgsql-hackers
On Wed, Mar 18, 2026 at 11:31 PM Álvaro Herrera <alvherre@kurilemu.de> wrote:
>
> On 2026-Mar-18, Álvaro Herrera wrote:
>
> > On 2026-03-17, Jeff Davis wrote:
> >
> > > Then we have to invent a deep copy for the Subscription, and we've
> > > already seen that the FreeSubscrpition() method was not being
> > > maintained properly.
> >
> > Maybe another possibility would be to use a separate memory context
> > for each subscription, initially making it a child of the transaction
> > context, and then reparenting it as appropriate.
>
> I mean something like this on top of your 0003.
>

+1. This approach and patch looks like a better way to deal with this issue.

-- 
With Regards,
Amit Kapila.



Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Document new catalog columns, missed in commit 8185bb5347.

  2. Refactor to remove ForeignServerName().

  3. GetSubscription(): use per-object memory context.

  4. Fix dependency on FDW's connection function.

  5. ALTER SUBSCRIPTION ... SERVER test.

  6. Fix pg_dump for CREATE FOREIGN DATA WRAPPER ... CONNECTION.

  7. Clean up postgres_fdw/t/010_subscription.pl.

  8. CREATE SUBSCRIPTION ... SERVER.

  9. Allow upgrades to preserve the full subscription's state.