Re: pgsql: Drop unnamed portal immediately after execution to completion

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Sami Imseih <samimseih(at)gmail(dot)com>
Cc: Mircea Cadariu <cadariu(dot)mircea(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Frédéric Yhuel <frederic(dot)yhuel(at)dalibo(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pgsql: Drop unnamed portal immediately after execution to completion
Date: 2025-11-14 06:04:25
Message-ID: aRbGaQTisuKMREuS@paquier.xyz
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On Thu, Nov 13, 2025 at 04:02:24PM -0600, Sami Imseih wrote:
> I am not sure I like this idea as-is, because besides that fact
> that it's still a wire level change, it's not safe at all to
> re-enter exec_execute_message after you just cleaned the
> portal but did not drop it.

This will come at the cost of tracking a new state in the backend
where the portal would still live with the executor state gone, I
don't like much my own plan D and the road where this leads at the
end.

> That is probably the best idea now.

I have just done a revert of 1fd981f05369 now, let's continue the
discussions.
--
Michael

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Álvaro Herrera 2025-11-14 11:01:10 pgsql: Doc: add IDs to copy.sgml's <varlistentry> and <refsect1>
Previous Message Michael Paquier 2025-11-14 05:41:23 pgsql: Revert "Drop unnamed portal immediately after execution to compl

Browse pgsql-hackers by date

  From Date Subject
Next Message Masahiko Sawada 2025-11-14 06:09:35 Re: Issue with logical replication slot during switchover
Previous Message Corey Huinker 2025-11-14 05:49:23 Re: Extended Statistics set/restore/clear functions.