pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Justin Pryzby <pryzby@telsasoft.com>
Cc: Andrew Dunstan <andrew@dunslane.net>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Adjust interaction of CREATEROLE with role properties.
Date: Sat, 28 Jan 2023 11:27:52 +0900
Message-ID: <Y9SIKM43sxo5Npp9@paquier.xyz> (raw)
In-Reply-To: <3332370.1674834413@sss.pgh.pa.us>
References: <CA+TgmoYyJrOkBtFpSpVaZML-EPnG9VwSpvicj8=5Sbu647KRcQ@mail.gmail.com>
<25633601-9749-a03c-e1cc-8ff2cf7c599a@dunslane.net>
<20230126183106.GS22427@telsasoft.com>
<Y9MZxVrCoutVbMCM@paquier.xyz>
<3248936.1674785303@sss.pgh.pa.us>
<Y9M/mqKqGXYt3jkC@paquier.xyz>
<3255990.1674789499@sss.pgh.pa.us>
<6c20449e-ac9c-7876-0d90-70a1ddea1076@dunslane.net>
<20230127152854.GY22427@telsasoft.com>
<3332370.1674834413@sss.pgh.pa.us>
On Fri, Jan 27, 2023 at 10:46:53AM -0500, Tom Lane wrote:
> I was imagining that pg_regress could contain a function that
> issues some predefined queries and complains if the results
> aren't empty. It already has the ability to issue commands
> to the cluster-under-test (for the initial CREATE DATABASE etc)
> so at least most of the infrastructure is easily at hand.
Agreed. I was also thinking among these lines this morning after
waking up. There is a pattern here, actually. Without storing full
queries, we could have a function that has arguments about:
- The attribute name to report back if we find an unwanted name.
- The catalog name to query.
- The qual to use.
That's an implementation detail, though.
There is also a gotcha that has not been mentioned yet: there should
be an option switch to control if this check is run or not. In the
tree, test_pg_dump is an exception where this is not going to work,
because we leave around the role regress_dump_test_role after repeated
installchecks. It has been argued in the past that this should be
cleaned up, but also counter-argued that this is useful for pg_upgrade
in the buildfarm with the dump of extensions.
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
view thread (13+ messages)
Message-ID: <Y9SIKM43sxo5Npp9@paquier.xyz> Permalink: ../Y9SIKM43sxo5Npp9@paquier.xyz/ Also on: postgresql.org/message-id/Y9SIKM43sxo5Npp9@paquier.xyz ·
reply
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 from your mail client; the link fills in the headers below: reply via email Some clients, webmail especially, drop In-Reply-To and References from a link, and the reply then starts a new thread: use the mbox below. To: pgsql-committers@postgresql.org Cc: michael@paquier.xyz, tgl@sss.pgh.pa.us, pryzby@telsasoft.com, andrew@dunslane.net, robertmhaas@gmail.com, alvherre@alvh.no-ip.org Subject: Re: pgsql: Adjust interaction of CREATEROLE with role properties. In-Reply-To: <Y9SIKM43sxo5Npp9@paquier.xyz> References: <CA+TgmoYyJrOkBtFpSpVaZML-EPnG9VwSpvicj8=5Sbu647KRcQ@mail.gmail.com> <25633601-9749-a03c-e1cc-8ff2cf7c599a@dunslane.net> <20230126183106.GS22427@telsasoft.com> <Y9MZxVrCoutVbMCM@paquier.xyz> <3248936.1674785303@sss.pgh.pa.us> <Y9M/mqKqGXYt3jkC@paquier.xyz> <3255990.1674789499@sss.pgh.pa.us> <6c20449e-ac9c-7876-0d90-70a1ddea1076@dunslane.net> <20230127152854.GY22427@telsasoft.com> <3332370.1674834413@sss.pgh.pa.us> <Y9SIKM43sxo5Npp9@paquier.xyz> * 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