From: | Álvaro Herrera <alvherre(at)kurilemu(dot)de> |
---|---|
To: | Antonin Houska <ah(at)cybertec(dot)at> |
Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: Unexpected changes of CurrentResourceOwner and CurrentMemoryContext |
Date: | 2025-09-11 18:05:32 |
Message-ID: | 202509111800.kp6xfq6pnke7@alvherre.pgsql |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2025-Sep-03, Antonin Houska wrote:
> When working on the REPACK command, we see an ERROR caused by unexpected
> change of CurrentResourceOwner [1]. I think the problem is that
> reorderbuffer.c does not restore the original value after calling
> RollbackAndReleaseCurrentSubTransaction(). The attached patch tries to handle
> the call like other callers throughout the tree do.
I have registered this as
https://commitfest.postgresql.org/patch/6051/
I've been wondering whether this should be backpatched. In principle
this is a bugfix, so it should, but I don't offhand recall any cases
where failure to set the current context/resowner in the other
reorderbuffer.c users causes a live bug, so ... maybe master only? I'm
wondering if it's possible where anybody _depends_ on the current
behavior, but I suppose that's quite unlikely.
It applies cleanly back to 14, so I would probably stop there in any
case. (A good thing also, because if we mess up 13 with it now and
don't notice until after the next minor is out, there won't be a chance
to unbreak it later.)
--
Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/
Essentially, you're proposing Kevlar shoes as a solution for the problem
that you want to walk around carrying a loaded gun aimed at your foot.
(Tom Lane)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2025-09-11 18:19:40 | Re: plan shape work |
Previous Message | Pierrick | 2025-09-11 18:03:07 | Re: Only one version can be installed when using extension_control_path |