Re: Review of Row Level Security

From: Dean Rasheed <dean(dot)a(dot)rasheed(at)gmail(dot)com>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: Stephen Frost <sfrost(at)snowman(dot)net>, Kevin Grittner <kgrittn(at)mail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Robert Haas <robertmhaas(at)gmail(dot)com>, Kohei KaiGai <kaigai(at)kaigai(dot)gr(dot)jp>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Review of Row Level Security
Date: 2012-12-21 10:04:36
Message-ID: CAEZATCXvaAw4T2KqOA+hU6pX6Pb6OqQrpeheQD0W4LpEbZorGA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 21 December 2012 09:29, Dean Rasheed <dean(dot)a(dot)rasheed(at)gmail(dot)com> wrote:
> On 21 December 2012 08:56, Simon Riggs <simon(at)2ndquadrant(dot)com> wrote:
>> It's unreasonable for people to demand a feature yet provide no
>> guidance to the person trying (hard) to provide that feature in a
>> sensible way. If people genuinely believe case (2) is worth pursuing,
>> additional work and input is needed so that KaiGai can make changes in
>> time for the 9.3 deadline. Please read what KaiGai has said and
>> respond. Since there are so many people reading this thread and
>> wanting (2), that seems reasonable to expect.
>>
>> What I have proposed is that I work on the review for case (1) and
>> then if we solve (2) that can go in also. I don't think its reasonable
>> to reject the whole feature because of unresolved difficulties around
>> one use case, which is what will happen if this is seen as merely a
>> debate about defaults.
>>
>
> One comment on the code itself -- I think it needs some locking of
> rows from the subquery to ensure correct concurrency behaviour when
> there are multiple transactions doing updates at the same time.
>

Another comment -- the use of the RangeTblEntry structure in the new
code is a bit odd. It seems to be creating an RTE that is both an
RTE_RELATION and an RTE_SUBQUERY at the same time. I think it would be
cleaner to just add a new RTE for the subquery (cf. the
trigger-updatable view code in ApplyRetrieveRule).

Regards,
Dean

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2012-12-21 12:20:00 need a function to extract list items from pg_node_tree
Previous Message Dean Rasheed 2012-12-21 09:29:38 Re: Review of Row Level Security