Re: [PATCH] plpython function causes server panic
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andres Freund <andres@anarazel.de>
Cc: Hao Zhang <zhrt1446384557@gmail.com>, pgsql-hackers@lists.postgresql.org
Date: 2023-12-02T01:51:11Z
Lists: pgsql-hackers
I wrote: > The only readily-reachable error case in BeginInternalSubTransaction > is this specific one about IsInParallelMode, which was added later > than the original design and evidently with not a lot of thought or > testing. The comment for it speculates about whether we could get > rid of it, so I wonder if our thoughts about this ought to go in that > direction. After thinking a bit more I wonder why we need that error check at all. Why isn't it sufficient to rely on GetNewTransactionId()'s check that throws an error if a parallelized subtransaction tries to obtain an XID? I don't see why we'd need to "synchronize transaction state" about anything that never acquires an XID. regards, tom lane
Commits
-
Allow "internal" subtransactions in parallel mode.
- 0075d78947e3 17.0 landed
-
Tighten up application of parallel mode checks.
- 94b4f7e2a635 9.6.0 cited