On Mon, Nov 28, 2022 at 2:45 PM Simon Riggs
<simon.riggs@enterprisedb.com> wrote:
> An easy point to confuse:
> "subtransaction to end": The subtransaction is "still running" to
> other backends even AFTER it has been subcommitted, but its state now
> transfers to the parent.
>
> So the subtransaction doesn't cease running until it aborts, one of
> its parent aborts or top level commit. The subxid lock should, on
> principle, exist until one of those events occurs. It doesn't, but
> that is an optimization, for the stated reason.
That's not what "running" means to me. Running means it's started and
hasn't yet committed or rolled back.
--
Robert Haas
EDB: http://www.enterprisedb.com