-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/27846/#review62796
-----------------------------------------------------------



sentry-provider/sentry-provider-db/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java
<https://reviews.apache.org/r/27846/#comment104917>

    It looks odd, but I do, actually.  I got this paradigm directly from here: 
http://www.datanucleus.org/products/datanucleus/jdo/transactions.html#readonly



sentry-provider/sentry-provider-db/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java
<https://reviews.apache.org/r/27846/#comment104927>

    Added.  But intellij actually complained that rollback would always be 
false at that point.  I think that intellij is right - by the time idList is 
added to, there aren't any more places where an exception could occur.  But 
anyway, better safe than sorry.


- Mike Yoder


On Nov. 21, 2014, 7:47 p.m., Mike Yoder wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/27846/
> -----------------------------------------------------------
> 
> (Updated Nov. 21, 2014, 7:47 p.m.)
> 
> 
> Review request for sentry.
> 
> 
> Bugs: SENTRY-140
>     https://issues.apache.org/jira/browse/SENTRY-140
> 
> 
> Repository: sentry
> 
> 
> Description
> -------
> 
> Due to the M-to-N relationship of roles to privileges, when a role is removed 
> from a privilege (or vice versa) that privilege is not deleted from the 
> database.  
> 
> This fix introduces a thread that periodically (currently, once every 10 
> times a role and a privilege are disassociated) runs a SQL query that 
> searches for all orphaned privileges and deletes them.
> 
> 
> Diffs
> -----
> 
>   
> sentry-provider/sentry-provider-db/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java
>  3615661 
>   
> sentry-provider/sentry-provider-db/src/main/java/org/apache/sentry/service/thrift/ServiceConstants.java
>  03ed378 
>   
> sentry-provider/sentry-provider-db/src/test/java/org/apache/sentry/provider/db/service/persistent/TestSentryStore.java
>  70917b7 
> 
> Diff: https://reviews.apache.org/r/27846/diff/
> 
> 
> Testing
> -------
> 
> Wrote a test case; local testing.
> 
> 
> Thanks,
> 
> Mike Yoder
> 
>

Reply via email to