From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andres Freund <andres@anarazel.de>
Cc: Peter Geoghegan <pg@bowt.ie>
Cc: hubert depesz lubaczewski <depesz@depesz.com>
Cc: PostgreSQL mailing lists <pgsql-bugs@lists.postgresql.org>
Subject: Re: Pg 15 devel crashes when fetching data from table using cursor
Date: Thu, 10 Mar 2022 21:21:13 -0500
Message-ID: <763986.1646965273@sss.pgh.pa.us> (raw)
In-Reply-To: <20220311021047.hgtqkrl6n52srvdu@alap3.anarazel.de>
References: <20220307094423.GA24798@depesz.com>
<20220311005045.vnwb3aa5htilh3rh@alap3.anarazel.de>
<CAH2-WzkHD5VDnswg_1qTQ45zqxQCAkkPwmmvL_8EX3Gut+mSbw@mail.gmail.com>
<20220311015030.irviiohj4e6rvdr5@alap3.anarazel.de>
<762946.1646964337@sss.pgh.pa.us>
<20220311021047.hgtqkrl6n52srvdu@alap3.anarazel.de>
Andres Freund <andres@anarazel.de> writes:
> I think we basically have to move the setting of PROC_IN_VACUUM to the last
> moment, when we've done everything else, and then force a new snapshot to be
> computed after.
Maybe we can add Assert(!PROC_IN_VACUUM) to catalog accesses?
But the main reason I'm concerned about this is that I fear people
will unthinkingly put catalog accesses into error paths, where
they might well not get exercised by any normal testing.
The poster child for this is something like
if (unlikely-condition)
elog(ERROR, "Houston, we have a problem with table %s",
get_rel_name(relid));
Assertions are unlikely to help us catch that.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, andres@anarazel.de, pg@bowt.ie, depesz@depesz.com, pgsql-bugs@lists.postgresql.org
Subject: Re: Pg 15 devel crashes when fetching data from table using cursor
In-Reply-To: <763986.1646965273@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox