You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sentry.apache.org by Na Li via Review Board <no...@reviews.apache.org> on 2019/03/01 04:01:00 UTC

Re: Review Request 70068: SENTRY-2503: Failed to revoke the privilege from impala-shell if the privilege added from beeline cli

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

(Updated March 1, 2019, 4:01 a.m.)


Review request for sentry and kalyan kumar kalvagadda.


Bugs: sentry-2503
    https://issues.apache.org/jira/browse/sentry-2503


Repository: sentry


Description
-------

When granting all privilege on a table from impala-shell, this privilege cannot be revoked from hiove beeline.

When granting all privilege on a table from hive beeline, this privilege cannot be revoked from impala-shell.

The reason is that impala uses "ALL" to represent all privilege, and hive uses "*". So getting privilege to drop it does not properly.

The solution is to find all equivalent privileges from input, and drop them.


Diffs (updated)
-----

  sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/QueryParamBuilder.java 240120c 
  sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java 1d97ff6 
  sentry-service/sentry-service-server/src/test/java/org/apache/sentry/provider/db/service/persistent/TestSentryStore.java 38b4c87 


Diff: https://reviews.apache.org/r/70068/diff/2/

Changes: https://reviews.apache.org/r/70068/diff/1-2/


Testing
-------

add new tests and all old tests in TestSentryStore pass


Thanks,

Na Li


Re: Review Request 70068: SENTRY-2503: Failed to revoke the privilege from impala-shell if the privilege added from beeline cli

Posted by Arjun Mishra via Review Board <no...@reviews.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/70068/#review213413
-----------------------------------------------------------


Ship it!




Ship It!

- Arjun Mishra


On March 4, 2019, 9:49 p.m., Na Li wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/70068/
> -----------------------------------------------------------
> 
> (Updated March 4, 2019, 9:49 p.m.)
> 
> 
> Review request for sentry and kalyan kumar kalvagadda.
> 
> 
> Bugs: sentry-2503
>     https://issues.apache.org/jira/browse/sentry-2503
> 
> 
> Repository: sentry
> 
> 
> Description
> -------
> 
> When granting all privilege on a table from impala-shell, this privilege cannot be revoked from hiove beeline.
> 
> When granting all privilege on a table from hive beeline, this privilege cannot be revoked from impala-shell.
> 
> The reason is that impala uses "ALL" to represent all privilege, and hive uses "*". So getting privilege to drop it does not properly.
> 
> The solution is to find all equivalent privileges from input, and drop them.
> 
> 
> Diffs
> -----
> 
>   sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/QueryParamBuilder.java 240120c 
>   sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java 1d97ff6 
>   sentry-service/sentry-service-server/src/test/java/org/apache/sentry/provider/db/service/persistent/TestSentryStore.java 38b4c87 
> 
> 
> Diff: https://reviews.apache.org/r/70068/diff/4/
> 
> 
> Testing
> -------
> 
> add new tests and all old tests in TestSentryStore pass
> 
> 
> Thanks,
> 
> Na Li
> 
>


Re: Review Request 70068: SENTRY-2503: Failed to revoke the privilege from impala-shell if the privilege added from beeline cli

Posted by Na Li via Review Board <no...@reviews.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/70068/
-----------------------------------------------------------

(Updated March 4, 2019, 9:49 p.m.)


Review request for sentry and kalyan kumar kalvagadda.


Bugs: sentry-2503
    https://issues.apache.org/jira/browse/sentry-2503


Repository: sentry


Description
-------

When granting all privilege on a table from impala-shell, this privilege cannot be revoked from hiove beeline.

When granting all privilege on a table from hive beeline, this privilege cannot be revoked from impala-shell.

The reason is that impala uses "ALL" to represent all privilege, and hive uses "*". So getting privilege to drop it does not properly.

The solution is to find all equivalent privileges from input, and drop them.


Diffs (updated)
-----

  sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/QueryParamBuilder.java 240120c 
  sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java 1d97ff6 
  sentry-service/sentry-service-server/src/test/java/org/apache/sentry/provider/db/service/persistent/TestSentryStore.java 38b4c87 


Diff: https://reviews.apache.org/r/70068/diff/4/

Changes: https://reviews.apache.org/r/70068/diff/3-4/


Testing
-------

add new tests and all old tests in TestSentryStore pass


Thanks,

Na Li


Re: Review Request 70068: SENTRY-2503: Failed to revoke the privilege from impala-shell if the privilege added from beeline cli

Posted by Arjun Mishra via Review Board <no...@reviews.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/70068/#review213412
-----------------------------------------------------------



Fix the annotation and ship it

- Arjun Mishra


On March 4, 2019, 8:46 p.m., Na Li wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/70068/
> -----------------------------------------------------------
> 
> (Updated March 4, 2019, 8:46 p.m.)
> 
> 
> Review request for sentry and kalyan kumar kalvagadda.
> 
> 
> Bugs: sentry-2503
>     https://issues.apache.org/jira/browse/sentry-2503
> 
> 
> Repository: sentry
> 
> 
> Description
> -------
> 
> When granting all privilege on a table from impala-shell, this privilege cannot be revoked from hiove beeline.
> 
> When granting all privilege on a table from hive beeline, this privilege cannot be revoked from impala-shell.
> 
> The reason is that impala uses "ALL" to represent all privilege, and hive uses "*". So getting privilege to drop it does not properly.
> 
> The solution is to find all equivalent privileges from input, and drop them.
> 
> 
> Diffs
> -----
> 
>   sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/QueryParamBuilder.java 240120c 
>   sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java 1d97ff6 
>   sentry-service/sentry-service-server/src/test/java/org/apache/sentry/provider/db/service/persistent/TestSentryStore.java 38b4c87 
> 
> 
> Diff: https://reviews.apache.org/r/70068/diff/3/
> 
> 
> Testing
> -------
> 
> add new tests and all old tests in TestSentryStore pass
> 
> 
> Thanks,
> 
> Na Li
> 
>


Re: Review Request 70068: SENTRY-2503: Failed to revoke the privilege from impala-shell if the privilege added from beeline cli

Posted by Arjun Mishra via Review Board <no...@reviews.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/70068/#review213411
-----------------------------------------------------------




sentry-service/sentry-service-server/src/test/java/org/apache/sentry/provider/db/service/persistent/TestSentryStore.java
Lines 4512 (patched)
<https://reviews.apache.org/r/70068/#comment299352>

    You need to add @Test here


- Arjun Mishra


On March 4, 2019, 8:46 p.m., Na Li wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/70068/
> -----------------------------------------------------------
> 
> (Updated March 4, 2019, 8:46 p.m.)
> 
> 
> Review request for sentry and kalyan kumar kalvagadda.
> 
> 
> Bugs: sentry-2503
>     https://issues.apache.org/jira/browse/sentry-2503
> 
> 
> Repository: sentry
> 
> 
> Description
> -------
> 
> When granting all privilege on a table from impala-shell, this privilege cannot be revoked from hiove beeline.
> 
> When granting all privilege on a table from hive beeline, this privilege cannot be revoked from impala-shell.
> 
> The reason is that impala uses "ALL" to represent all privilege, and hive uses "*". So getting privilege to drop it does not properly.
> 
> The solution is to find all equivalent privileges from input, and drop them.
> 
> 
> Diffs
> -----
> 
>   sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/QueryParamBuilder.java 240120c 
>   sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java 1d97ff6 
>   sentry-service/sentry-service-server/src/test/java/org/apache/sentry/provider/db/service/persistent/TestSentryStore.java 38b4c87 
> 
> 
> Diff: https://reviews.apache.org/r/70068/diff/3/
> 
> 
> Testing
> -------
> 
> add new tests and all old tests in TestSentryStore pass
> 
> 
> Thanks,
> 
> Na Li
> 
>


Re: Review Request 70068: SENTRY-2503: Failed to revoke the privilege from impala-shell if the privilege added from beeline cli

Posted by Na Li via Review Board <no...@reviews.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/70068/
-----------------------------------------------------------

(Updated March 4, 2019, 8:46 p.m.)


Review request for sentry and kalyan kumar kalvagadda.


Bugs: sentry-2503
    https://issues.apache.org/jira/browse/sentry-2503


Repository: sentry


Description
-------

When granting all privilege on a table from impala-shell, this privilege cannot be revoked from hiove beeline.

When granting all privilege on a table from hive beeline, this privilege cannot be revoked from impala-shell.

The reason is that impala uses "ALL" to represent all privilege, and hive uses "*". So getting privilege to drop it does not properly.

The solution is to find all equivalent privileges from input, and drop them.


Diffs (updated)
-----

  sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/QueryParamBuilder.java 240120c 
  sentry-service/sentry-service-server/src/main/java/org/apache/sentry/provider/db/service/persistent/SentryStore.java 1d97ff6 
  sentry-service/sentry-service-server/src/test/java/org/apache/sentry/provider/db/service/persistent/TestSentryStore.java 38b4c87 


Diff: https://reviews.apache.org/r/70068/diff/3/

Changes: https://reviews.apache.org/r/70068/diff/2-3/


Testing
-------

add new tests and all old tests in TestSentryStore pass


Thanks,

Na Li