On Sat, Dec 1, 2012 at 2:57 AM, Kohei KaiGai <kai...@kaigai.gr.jp> wrote: > * Do we need OAT_POST_ALTER hook even if no fields were updated > actually? In case when ALTER SET OWNER, it checks object's ownership > only when current and new user-id is not same. Right now, I follow this > manner on OAT_POST_ALTER invocation. > However, I'm inclined to consider the hook should be invoked when no > fields are actually updated also. (It allows extension-side to determine > necessity of processing something.)
I agree. I think it should always be called. > * When tablespace of relation was changed, it seems to me the point to > invoke OAT_POST_ALTER hook should be "after" ATRewriteTable(). > However, it usually long time to rewrite whole the table if it already have > large number of rows. I'm not 100% certain to put hook here, so this > version does not support hook when tablespace changes. Well, if it's a post-alter hook, it should presumably happen as close to the end of processing as possible. But are you sure that's really what you want? I would think that for SE-Linux you'd be wanting to get control much earlier in the process. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers