Alvaro Herrera <[EMAIL PROTECTED]> writes:
> On Tue, Jul 05, 2005 at 03:51:32PM -0400, Tom Lane wrote:
> An important distinction to be made is which dependencies are "auto" and
> which ones are "normal".  It's clear that OWNER entries cannot be AUTO.
> OTOH grantee entries in the ACL can be (have to be) dropped
> automatically, but what to do about grantor ones?  We may have to do a
> distinction.  We could drop the grants for which the dropped user is the
> grantor; but not automatically, I think.

For the moment I left this alone; you can revisit the question when
you do DROP OWNED or whatever we end up calling it.

I've committed the patch with some revisions --- principally that I took
out tracking of dependencies on tablespaces, as I couldn't see any real
argument that we need to track that separately from the filesystem
structure.  (I was also a bit concerned about whether copying a database
to a different default tablespace would work correctly.)

I ended up calling the dependency types OWNER and ACL; there is no
NORMAL at the moment.  Obviously we'd need to add more dependency types
to track dependencies on anything but roles.  The reason for this is
that getting the ALTER OWNER case right requires removing ACL dependency
entries for the new owner, and I didn't like the idea of issuing a
blanket removal except against a very specifically defined dependency
type.  Also, I figured out why you needed the separate OWNER dependency
type: it's so you can tell which entry to update during ALTER OWNER.
This is hopefully a bit better documented now.

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to