From: | "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> |
---|---|
To: | Étienne BERSAC <etienne(dot)bersac(at)dalibo(dot)com> |
Cc: | "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: REVOKE FROM warning on grantor |
Date: | 2024-03-14 14:03:09 |
Message-ID: | CAKFQuwZ4F126-Q8LkAocJuhuPSEBX8kA8wNctnkfP5DvcUz5eg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thursday, March 14, 2024, Étienne BERSAC <etienne(dot)bersac(at)dalibo(dot)com>
wrote:
>
> However, I'd prefer if Postgres fails properly. Because the GRANT is
> actually not revoked. This prevent ldap2pg to report an issue in
> handling privileges on such roles.
>
> What do you think of make this warning an error ?
>
>
The choice of warning is made because after the command ends the grantmin
question does not exist. The revoke was a no-op and the final state is as
the user intended. Historically doing this didn’t give any message at all
which was confusing so we added a warning so the semantics of not failing
were preserved but there was some indication that something was amiss. I
don’t have a compelling argument to,change the long-standing behavior.
Client code can and probably should look for a show errors reported by the
backend. It is indeed possibly to treat this warning more serverly than
the server chooses to.
David J.
From | Date | Subject | |
---|---|---|---|
Next Message | Alvaro Herrera | 2024-03-14 14:04:12 | Re: MERGE ... RETURNING |
Previous Message | Alvaro Herrera | 2024-03-14 14:03:07 | Re: Catalog domain not-null constraints |