From: Heikki Linnakangas <hlinnaka@iki.fi>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: Andrew Dunstan <andrew@dunslane.net>
Cc: pgsql-committers@lists.postgresql.org, Sami Imseih <samimseih@gmail.com>
Subject: Re: pgsql: injection_points: Remove portions related to custom pgstats
Date: Tue, 9 Dec 2025 22:04:43 +0200
Message-ID: <ebfa8b0a-5858-4167-884c-499e70fce2cd@iki.fi> (raw)
In-Reply-To: <251242.1765302019@sss.pgh.pa.us>
References: <E1vSSCn-003N0Z-2i@gemulon.postgresql.org>
<2899652.1765167313@sss.pgh.pa.us>
<aTZZzFhQTtUKWGLm@paquier.xyz>
<2904427.1765169854@sss.pgh.pa.us>
<aTaPKpYufxut5Zs1@paquier.xyz>
<d92f0eca-bb14-4b8c-9fb0-3b79635e1a64@iki.fi>
<251242.1765302019@sss.pgh.pa.us>
On 09/12/2025 19:40, Tom Lane wrote:
> Perhaps another alternative is to add "DROP EXTENSION
> injection_points" at the end of the test scripts in the
> problematic modules.
It's a little tricky if a module has more than one test that uses the
extension. Namely src/test/modules/nbtree which I added recently has two
test scripts, nbtree_incomplete_splits.sql and
nbtree_half_dead_pages.sql, and both of them do "create extension if not
exists injection_points;". They run concurrently, so they race on which
one creates the extension first. We can't do the same for DROP EXTENSION
at the end.
Maybe that's not a great design in the first place, though. Perhaps that
module should use a schedule file:
# create injection_points extension before the actual tests
test: test_setup
test: nbtree_incomplete_splits nbtree_half_dead_pages
# drop injection_points extension because it cannot be pg_upgraded.
test: test_clean
- Heikki
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-committers@postgresql.org
Cc: hlinnaka@iki.fi, tgl@sss.pgh.pa.us, michael@paquier.xyz, andrew@dunslane.net, samimseih@gmail.com
Subject: Re: pgsql: injection_points: Remove portions related to custom pgstats
In-Reply-To: <ebfa8b0a-5858-4167-884c-499e70fce2cd@iki.fi>
* 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