Re: update portal-related memory context names and API

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: update portal-related memory context names and API
Date: 2018-01-08 21:14:49
Message-ID: 20180108211449.yr4li74ii65yr52g@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut wrote:

> Subject: [PATCH 1/2] Update portal-related memory context names and API
>
> Rename PortalMemory to TopPortalContext, to avoid confusion with
> PortalContext and align naming with similar top-level memory contexts.
>
> Rename PortalData's "heap" field to portalContext. The "heap" naming
> seems quite antiquated and confusing. Also get rid of the
> PortalGetHeapMemory() macro and access the field directly, which we do
> for other portal fields, so this abstraction doesn't buy anything.

This one looks good to me. I was long confused by that "heap"
terminology.

> Subject: [PATCH 2/2] Remove PortalGetQueryDesc()
>
> After having gotten rid of PortalGetHeapMemory(), there seems little
> reason to keep one Portal access macro around that offers no actual
> abstraction and isn't consistently used anyway.

This macro does look quite pointless.

--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2018-01-08 21:29:49 Re: Parallel append plan instability/randomness
Previous Message Alvaro Herrera 2018-01-08 20:54:59 Re: [HACKERS] Proposal: Local indexes for partitioned table