public inbox for [email protected]
help / color / mirror / Atom feedFrom: Gilles Darold <[email protected]>
To: Nathan Bossart <[email protected]>
Cc: Andrew Dunstan <[email protected]>
Cc: Justin Pryzby <[email protected]>
Cc: [email protected]
Cc: Robert Haas <[email protected]>
Subject: Re: fix and document CLUSTER privileges
Date: Wed, 4 Jan 2023 14:25:13 +0100
Message-ID: <[email protected]> (raw)
In-Reply-To: <20221216045700.GA804311@nathanxps13>
References: <20221207223924.GA4182184@nathanxps13>
<[email protected]>
<20221208041313.GA216874@nathanxps13>
<[email protected]>
<20221208181324.GA4385@nathanxps13>
<CA+TgmoaWhAjTP3a9xjA2P=xkF-RV9UOYT11JVWgQq5A8AB9ZrA@mail.gmail.com>
<20221214173435.GA690225@nathanxps13>
<20221216045700.GA804311@nathanxps13>
Le 16/12/2022 à 05:57, Nathan Bossart a écrit :
> Here is a new version of the patch. I've moved the privilege checks to a
> new function, and I added a note in the docs about clustering partitioned
> tables in a transaction block (it's not allowed).
>
Getting into review of this patch I wonder why the CLUSTER command do
not react as VACUUM FULL command when there is insuffisant privileges.
For example with a partitioned table (ptnowner) and two partitions
(ptnowner1 and ptnowner2) with the second partition owned by another
user, let' say usr2. We have the following report when executing vacuum
as usr2:
testdb=> VACUUM FULL ptnowner;
WARNING: permission denied to vacuum "ptnowner", skipping it
WARNING: permission denied to vacuum "ptnowner1", skipping it
VACUUM
Here only ptnowner2 have been vacuumed which is correct and expected.
For the cluster command:
testdb=> CLUSTER;
CLUSTER
I would have expected something like:
testdb=> CLUSTER;
WARNING: permission denied to cluster "ptnowner1", skipping it
CLUSTER
I mean that the silent behavior is not very helpful.
This is the current behavior of the CLUSTER command and current patch
adds a sentence about the silent behavior in the documentation. This is
good but I just want to ask if we could want to fix this behavior too or
just keep things like that with the lack of noise.
Best regards,
--
Gilles Darold
view thread (2+ messages)
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 using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected], [email protected], [email protected]
Subject: Re: fix and document CLUSTER privileges
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox